diff options
author | Vadim Zhukov <zhuk@cvs.openbsd.org> | 2015-10-26 17:55:33 +0000 |
---|---|---|
committer | Vadim Zhukov <zhuk@cvs.openbsd.org> | 2015-10-26 17:55:33 +0000 |
commit | 8706fe48529b776e652c70000a26bd6cc7e29149 (patch) | |
tree | 53224fbb022d16d2e7d332c1fdf261f60c0b803d /usr.sbin/repquota | |
parent | 47620ed4fea896c1b668356b6899c5d105c718c9 (diff) |
Put repquota in line with other utilities: you either wants list everyting,
effectively using -a, or you specify filesystems one-by-one. Doing both
resulted in a funny error messages, so just don't allow that silly behaviour.
okay millert@
Diffstat (limited to 'usr.sbin/repquota')
-rw-r--r-- | usr.sbin/repquota/repquota.8 | 13 | ||||
-rw-r--r-- | usr.sbin/repquota/repquota.c | 2 |
2 files changed, 9 insertions, 6 deletions
diff --git a/usr.sbin/repquota/repquota.8 b/usr.sbin/repquota/repquota.8 index 1c173e5efee..9bfb87fd793 100644 --- a/usr.sbin/repquota/repquota.8 +++ b/usr.sbin/repquota/repquota.8 @@ -1,4 +1,4 @@ -.\" $OpenBSD: repquota.8,v 1.10 2007/05/31 19:20:28 jmc Exp $ +.\" $OpenBSD: repquota.8,v 1.11 2015/10/26 17:55:32 zhuk Exp $ .\" .\" Copyright (c) 1983, 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. @@ -31,17 +31,20 @@ .\" SUCH DAMAGE. .\" .\" from: @(#)repquota.8 8.1 (Berkeley) 6/6/93 -.\" $Id: repquota.8,v 1.10 2007/05/31 19:20:28 jmc Exp $ +.\" $Id: repquota.8,v 1.11 2015/10/26 17:55:32 zhuk Exp $ .\" -.Dd $Mdocdate: May 31 2007 $ +.Dd $Mdocdate: October 26 2015 $ .Dt REPQUOTA 8 .Os .Sh NAME .Nm repquota .Nd summarize quotas for a file system .Sh SYNOPSIS -.Nm repquota -.Op Fl aguv +.Nm +.Op Fl guv +.Fl a +.Nm +.Op Fl guv .Ar filesystem ... .Sh DESCRIPTION .Nm diff --git a/usr.sbin/repquota/repquota.c b/usr.sbin/repquota/repquota.c index 8376bea3210..bbde734daaf 100644 --- a/usr.sbin/repquota/repquota.c +++ b/usr.sbin/repquota/repquota.c @@ -102,7 +102,7 @@ main(int argc, char *argv[]) } argc -= optind; argv += optind; - if (argc == 0 && !aflag) + if ((argc == 0) == (aflag == 0)) usage(); if (!gflag && !uflag) { if (aflag) |