aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/pw/pw_group.c
diff options
context:
space:
mode:
authorDavid Nugent <davidn@FreeBSD.org>1999-10-26 08:34:09 +0000
committerDavid Nugent <davidn@FreeBSD.org>1999-10-26 08:34:09 +0000
commit2399cd14a7ea5aac021a7c204560dda8a5078b09 (patch)
tree2aa1f2f02b890aebacec8f3289cb2e2be16b19ca /usr.sbin/pw/pw_group.c
parent480207ab3dc5288eb80f864e3d33d2c3917b8e6b (diff)
downloadsrc-2399cd14a7ea5aac021a7c204560dda8a5078b09.tar.gz
src-2399cd14a7ea5aac021a7c204560dda8a5078b09.zip
Notes
Diffstat (limited to 'usr.sbin/pw/pw_group.c')
-rw-r--r--usr.sbin/pw/pw_group.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.sbin/pw/pw_group.c b/usr.sbin/pw/pw_group.c
index 54125d829ff6..d489a6b3c1a8 100644
--- a/usr.sbin/pw/pw_group.c
+++ b/usr.sbin/pw/pw_group.c
@@ -60,12 +60,14 @@ pw_group(struct userconf * cnf, int mode, struct cargs * args)
NULL
};
+ if (mode == M_LOCK || mode == M_UNLOCK)
+ errx(EX_USAGE, "'lock' command is not available for groups");
+
/*
* With M_NEXT, we only need to return the
* next gid to stdout
*/
- if (mode == M_NEXT)
- {
+ if (mode == M_NEXT) {
gid_t next = gr_gidpolicy(cnf, args);
if (getarg(args, 'q'))
return next;