Subject: Re: CVS commit: src/bin/ls
To: None <source-changes@NetBSD.org>
From: Perry E. Metzger <perry@piermont.com>
List: source-changes
Date: 04/08/2006 16:30:40
Jan Schaumann <jschauma@netmeister.org> writes:
> Alan Barrett <apb@cequrux.com> wrote:
>> On Sat, 08 Apr 2006, YAMAMOTO Takashi wrote:
>> > Modified Files:
>> > 	src/bin/ls: ls.1
>> > 
>> > Log Message:
>> > s/non-graphic/non-printable/ to match with the code.
>> 
>> I'd prefer to fix the code, as requested in PR 30374.
>
> Which solution, though?  I think option 3 is the best one:
>
> "Modify the man page to match the behaviour of "ls -q", and
> modify both the behaviour and documentation for "ls -b" and "ls -B" to
> make spaces readily apparent.  This could be done by adding VIS_WHITE
> to the flags passed to strvis(3) in the safe_print() function in
> src/bin/ls/util.c."
>
> Running 'ls -b "foo bar"' yields:
>
> On Lunix:   foo\ bar
> On IRIX:    foo\0x4bar
> On Solaris: foo bar
> On NetBSD:  foo bar

I think shockingly, the Linux behavior seems most in accord with what
one would expect -b to do (and with what is most useful to the user.)

Perry