NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: standards/38754: /bin/rm rm.c consistancy with other bsds



The following reply was made to PR standards/38754; it has been noted by GNATS.

From: "Greg A. Woods; Planix, Inc." <woods%planix.ca@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: standards-manager%netbsd.org@localhost,
 murray%river-styx.org@localhost
Subject: Re: standards/38754: /bin/rm rm.c consistancy with other bsds
Date: Mon, 2 Jun 2008 12:58:53 -0400

 On 2-Jun-08, at 2:50 AM, Murray Armfield wrote:
 >> From: Alan Barrett <apb%cequrux.com@localhost>
 >> Date: Mon, 2 Jun 2008 00:00:13 +0100
 >>
 >> On Mon, 26 May 2008, murray%river-styx.org@localhost wrote:
 >>> rm will display the usage message if there are no file arguments and
 >>> the -f flag is used. This does not follow POSIX. POSIX says...
 >>> "Do not write diagnostic messages or modify the exit status in the
 >>> case of nonexistent operands."
 >>
 >> You seem to interpret "nonexistent operands" to mean the number of
 >> operands (not counting options such as the "-f" itself) is zero.
 >>
 >> I believe that "nonexistent operands" should be interpreted to mean
 >> operands that contain strings that do not refer to entities that  
 >> exist
 >> in the file system.
 >>
 >> Thus, "rm -f" does not contain any "nonexistent operands"; it  
 >> contains
 >> no operands at all, and "rm" should print a diagnostic message
 >> complaining about incorrect usage, and exit with an error status.
 >>
 >> However, "rm -f /this/file/or/directory/does/not/exist" does contain
 >> a "nonexistent operand", and "rm" should exit without any error or
 >> diagnostic message.
 >>
 >> --apb (Alan Barrett)
 >
 > I see your point. "Nonexistent operands" could refer to no operands,  
 > or no
 > operands that exist.
 
 FWIW, In the way that I normally read documents, especially standards  
 documents, I believe Alan's interpretation is the correct one.
 
 "non-existant operands" are operands that do not exist.
 
 Any decent document, and especially a standards document, would  
 normally say "no operands" when it means "no operands".  An operand  
 cannot exist, or "not exist", if it is not given.  ;-)
 
 -- 
                                        Greg A. Woods; Planix, Inc.
                                        <woods%planix.ca@localhost>
 


Home | Main Index | Thread Index | Old Index