Date: Mon, 1 Mar 2004 11:25:27 -0800 (PST) From: Colin Percival <cperciva@FreeBSD.org> To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/bin/ls print.c Message-ID: <200403011925.i21JPRgL043927@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
cperciva 2004/03/01 11:25:27 PST
FreeBSD src repository
Modified files:
bin/ls print.c
Log:
Fixes to output of `ls -lh` for certain file sizes:
1. Sizes in the range 1000 -- 1023 units require four characters width
for the integer; increase the field width to accomodate this.
2. Sizes in the range 9.95 -- 10 units were being displayed as "10.0"
units; adjust the logic to fix this, and now that we've got an extra
character of field width, print fractional units if the size is less
than 99.95 units.
3. Don't display sub-byte precision.
This should mean that the following sizes are displayed:
0B .. 1023B
1.0U .. 9.9U
10.0U .. 99.9U
100U .. 1023U
for values of U in "KMGTPE".
PR: bin/63547
Pointy hat to: cperciva
Approved by: rwatson (mentor)
Revision Changes Path
1.68 +4 -4 src/bin/ls/print.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200403011925.i21JPRgL043927>
