X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-1.4 required=5.0 tests=AWL,BAYES_00,HK_OBFDOM,SPF_PASS X-Spam-Check-By: sourceware.org Message-ID: From: To: Subject: fuser exit codes (bug?) Date: Wed, 26 Aug 2009 19:23:32 +0000 Content-Type: text/plain; charset="windows-1256" Content-Transfer-Encoding: 8bit MIME-Version: 1.0 Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Hello, I wonder if the fuser utility coming with Cygwin is returning an error code that isn't in line with the IEEE specifaction. What is happening: --- somogyib AT demuc12306 ~ $ fuser /cygdrive/f/Bazsi/cygwin/bin/bash; echo $? /cygdrive/f/Bazsi/cygwin/bin/bash: 2708e 0 somogyib AT demuc12306 ~ $ fuser /cygdrive/f/Bazsi/cygwin/bin/awk; echo $? 1 --- So, the "bash" file is locked by one process and "awk" is by zero. For both scenarios FreeBSD returns 0 which I assume to be correct. The IEEE standard says fuser should return non-zero value only when an error occured. --- www.unix.org\single_unix_specification\susv3\utilities\fuser.html EXIT STATUS The following exit values shall be returned: 0 Successful completion. >0 An error occurred. --- A file being locked by one, two or ZERO process is all positive scenario so fuser should return 0. What's you opinion? Can this be fixed? Cheers, Balazs _________________________________________________________________ Drag n’ drop—Get easy photo sharing with Windows Live™ Photos. http://www.microsoft.com/windows/windowslive/products/photos.aspx -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple