From bf34e1e172273d2a7d9f04063d1d02b66bfa5123 Mon Sep 17 00:00:00 2001 From: mpp Date: Mon, 18 Feb 2008 01:36:40 +0000 Subject: Make the human readable numbers printed with the -h option a bit more human readable by telling the human print routines to use a smaller buffer to format the value. This makes it so a value that was previously being printed as 600000K will now print as 586M. --- usr.bin/quota/quota.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'usr.bin/quota') diff --git a/usr.bin/quota/quota.c b/usr.bin/quota/quota.c index c007e52..c725ad9 100644 --- a/usr.bin/quota/quota.c +++ b/usr.bin/quota/quota.c @@ -350,10 +350,12 @@ showquotas(int type, u_long id, const char *name) } printf("%15s", nam); if (hflag) { - prthumanval(7, dbtob(qup->dqblk.dqb_curblocks)); - printf("%c", (msgb == (char *)0) ? ' ' : '*'); - prthumanval(6, dbtob(qup->dqblk.dqb_bsoftlimit)); - prthumanval(7, dbtob(qup->dqblk.dqb_bhardlimit)); + printf(" "); + prthumanval(4, dbtob(qup->dqblk.dqb_curblocks)); + printf("%c ", (msgb == (char *)0) ? ' ' : '*'); + prthumanval(4, dbtob(qup->dqblk.dqb_bsoftlimit)); + printf(" "); + prthumanval(4, dbtob(qup->dqblk.dqb_bhardlimit)); } else { printf(" %7ju%c %6ju %7ju", (uintmax_t)(dbtob(qup->dqblk.dqb_curblocks) -- cgit v1.1