diff options
author | bapt <bapt@FreeBSD.org> | 2015-06-07 21:57:20 +0000 |
---|---|---|
committer | bapt <bapt@FreeBSD.org> | 2015-06-07 21:57:20 +0000 |
commit | 65b30fab70c3b273f9797608833f522b5a12f43d (patch) | |
tree | b96a72037293bea2a3f88582050e19a741969d24 /usr.sbin/pw/pw_user.c | |
parent | b0235ac2ee534e2b1b0cf6d6bfb141458d57690a (diff) | |
download | FreeBSD-src-65b30fab70c3b273f9797608833f522b5a12f43d.zip FreeBSD-src-65b30fab70c3b273f9797608833f522b5a12f43d.tar.gz |
Remove '-q' support for pw [user|group] next
the intent of -q in this command is to return as exit status the value of the
next group/user id, which does not make sense given exit status are limited to
values between 0 and 255.
Diffstat (limited to 'usr.sbin/pw/pw_user.c')
-rw-r--r-- | usr.sbin/pw/pw_user.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/usr.sbin/pw/pw_user.c b/usr.sbin/pw/pw_user.c index c3b2751..ea3cb3d 100644 --- a/usr.sbin/pw/pw_user.c +++ b/usr.sbin/pw/pw_user.c @@ -158,14 +158,10 @@ pw_user(int mode, char *name, long id, struct cargs * args) * With M_NEXT, we only need to return the * next uid to stdout */ - if (mode == M_NEXT) - { - uid_t next = pw_uidpolicy(cnf, id); - if (getarg(args, 'q')) - return next; - printf("%u:", next); + if (mode == M_NEXT) { + printf("%u:", pw_uidpolicy(cnf, id)); pw_group(mode, name, -1, args); - return EXIT_SUCCESS; + return (EXIT_SUCCESS); } /* |