sbase

suckless unix tools
git clone git://git.suckless.org/sbase
Log | Files | Refs | README | LICENSE

commit 2d7d2261a06a293ef6e27ad964f6bfb41fca8728
parent 97ce9ea586582d750af1476db8e7ef03ab698b7a
Author: FRIGN <dev@frign.de>
Date:   Wed,  2 Mar 2016 11:28:18 +0100

Really force 1 entry per line with -1 in ls(1)

if a filename contains a \n, it would not be limited to one line.
We use the qflag to replace the control characters with '?'s.

Diffstat:
Mls.c | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/ls.c b/ls.c @@ -369,7 +369,8 @@ main(int argc, char *argv[]) ARGBEGIN { case '1': - /* ignore */ + /* force output to 1 entry per line */ + qflag = 1; break; case 'A': Aflag = 1;