diff options
author | Otto Moerbeek <otto@cvs.openbsd.org> | 2005-04-03 19:02:31 +0000 |
---|---|---|
committer | Otto Moerbeek <otto@cvs.openbsd.org> | 2005-04-03 19:02:31 +0000 |
commit | 2a84335088b17863bfb6ba7b15f23c512855adbb (patch) | |
tree | 563629bc6d7cfd8e233ae1f73fdeb2bf7f191b1f | |
parent | 50661b05fe92134a31865acae626c43222b3806a (diff) |
Report quotas > 10GB in a readable way. Diff based on PR 2836.
ok deraadt@
-rw-r--r-- | usr.bin/quota/quota.c | 10 | ||||
-rw-r--r-- | usr.sbin/repquota/repquota.c | 6 |
2 files changed, 8 insertions, 8 deletions
diff --git a/usr.bin/quota/quota.c b/usr.bin/quota/quota.c index 52aa1ce476a..02506020f8d 100644 --- a/usr.bin/quota/quota.c +++ b/usr.bin/quota/quota.c @@ -1,4 +1,4 @@ -/* $OpenBSD: quota.c,v 1.25 2005/04/01 04:31:09 deraadt Exp $ */ +/* $OpenBSD: quota.c,v 1.26 2005/04/03 19:02:30 otto Exp $ */ /* * Copyright (c) 1980, 1990, 1993 @@ -41,7 +41,7 @@ static const char copyright[] = #ifndef lint /*static char sccsid[] = "from: @(#)quota.c 8.1 (Berkeley) 6/6/93";*/ static const char rcsid[] = -"$OpenBSD: quota.c,v 1.25 2005/04/01 04:31:09 deraadt Exp $"; +"$OpenBSD: quota.c,v 1.26 2005/04/03 19:02:30 otto Exp $"; #endif /* not lint */ /* @@ -360,7 +360,7 @@ showquotas(int type, u_long id, const char *name) printf("%s\n", qup->fsname); nam = ""; } - printf("%15s%8d%c%7d%8d%8s", + printf("%12s %7d%c %7d %7d %7s", nam, (int)(dbtob((u_quad_t)qup->dqblk.dqb_curblocks) / 1024), @@ -371,7 +371,7 @@ showquotas(int type, u_long id, const char *name) / 1024), (msgb == (char *)0) ? "" : timeprt(qup->dqblk.dqb_btime)); - printf("%8d%c%7d%8d%8s\n", + printf(" %7d%c %7d %7d %7s\n", qup->dqblk.dqb_curinodes, (msgi == (char *)0) ? ' ' : '*', qup->dqblk.dqb_isoftlimit, @@ -393,7 +393,7 @@ heading(int type, u_long id, const char *name, const char *tag) printf("Disk quotas for %s %s (%cid %ld): %s\n", qfextension[type], name, *qfextension[type], id, tag); if (!qflag && tag[0] == '\0') { - printf("%15s%8s %7s%8s%8s%8s %7s%8s%8s\n", + printf("%12s%8s%9s%8s%8s%9s%8s%8s%8s\n", "Filesystem", "KBytes", "quota", diff --git a/usr.sbin/repquota/repquota.c b/usr.sbin/repquota/repquota.c index a50f16df954..fe5f597ed79 100644 --- a/usr.sbin/repquota/repquota.c +++ b/usr.sbin/repquota/repquota.c @@ -38,7 +38,7 @@ static char copyright[] = #ifndef lint /*static char sccsid[] = "from: @(#)repquota.c 8.1 (Berkeley) 6/6/93";*/ -static char *rcsid = "$Id: repquota.c,v 1.26 2005/04/01 04:31:11 deraadt Exp $"; +static char *rcsid = "$Id: repquota.c,v 1.27 2005/04/03 19:02:30 otto Exp $"; #endif /* not lint */ /* @@ -218,7 +218,7 @@ repquota(struct fstab *fs, int type, char *qfpathname) fup->fu_dqblk.dqb_curblocks == 0) continue; printf("%-10s", fup->fu_name); - printf("%c%c%8d%8d%8d%7s", + printf("%c%c %7d %7d %7d %6s", fup->fu_dqblk.dqb_bsoftlimit && fup->fu_dqblk.dqb_curblocks >= fup->fu_dqblk.dqb_bsoftlimit ? '+' : '-', @@ -235,7 +235,7 @@ repquota(struct fstab *fs, int type, char *qfpathname) fup->fu_dqblk.dqb_curblocks >= fup->fu_dqblk.dqb_bsoftlimit ? timeprt(fup->fu_dqblk.dqb_btime) : ""); - printf(" %6d%6d%6d%7s\n", + printf(" %6d %5d %5d %6s\n", fup->fu_dqblk.dqb_curinodes, fup->fu_dqblk.dqb_isoftlimit, fup->fu_dqblk.dqb_ihardlimit, |