Date: Fri, 23 Aug 2002 15:40:55 +0200 (CEST) From: Lukas Ertl <le@univie.ac.at> To: FreeBSD-gnats-submit@FreeBSD.org Subject: bin/41936: [PATCH] edquota units are shown as blocks, but are kbytes Message-ID: <200208231340.g7NDetZQ003422@pcle2.cc.univie.ac.at>
next in thread | raw e-mail | index | archive | help
>Number: 41936
>Category: bin
>Synopsis: [PATCH] edquota units are shown as blocks, but are kbytes
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Fri Aug 23 06:50:01 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator: Lukas Ertl
>Release: FreeBSD 4.6-STABLE i386
>Organization:
Vienna University Computer Center
>Environment:
System: FreeBSD pcle2.cc.univie.ac.at 4.6-STABLE FreeBSD 4.6-STABLE #0: Mon Aug 19 19:18:42 CEST 2002 le@pcle2.cc.univie.ac.at:/usr/obj/usr/src/sys/PCLE2 i386
>Description:
The units shown in /usr/sbin/edquota ("blocks in use", "soft limit",
"hard limit") are called "blocks" but really are kbytes, which is quite
confusing.
>How-To-Repeat:
configure a filesystem with quotas, run "edquota <user>".
>Fix:
--- edquota.diff begins here ---
--- edquota.c Fri Aug 23 15:24:45 2002
+++ edquota.c.new Fri Aug 23 15:28:20 2002
@@ -423,7 +423,7 @@
fprintf(fd, "Quotas for %s %s:\n", qfextension[quotatype], name);
for (qup = quplist; qup; qup = qup->next) {
fprintf(fd, "%s: %s %lu, limits (soft = %lu, hard = %lu)\n",
- qup->fsname, "blocks in use:",
+ qup->fsname, "kbytes in use:",
(unsigned long)(dbtob(qup->dqblk.dqb_curblocks) / 1024),
(unsigned long)(dbtob(qup->dqblk.dqb_bsoftlimit) / 1024),
(unsigned long)(dbtob(qup->dqblk.dqb_bhardlimit) / 1024));
@@ -474,7 +474,7 @@
return (0);
}
cnt = sscanf(cp,
- " blocks in use: %lu, limits (soft = %lu, hard = %lu)",
+ " kbytes in use: %lu, limits (soft = %lu, hard = %lu)",
&curblocks, &bsoftlimit, &bhardlimit);
if (cnt != 3) {
warnx("%s:%s: bad format", fsp, cp);
--- edquota.diff ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200208231340.g7NDetZQ003422>
