diff options
author | markj <markj@FreeBSD.org> | 2016-03-02 04:56:36 +0000 |
---|---|---|
committer | markj <markj@FreeBSD.org> | 2016-03-02 04:56:36 +0000 |
commit | 87175eabd73e5562787b2fe36328556a4f0df6a4 (patch) | |
tree | 583ab230fa3e1ed98b9debf05b15053db6b24bf7 /usr.sbin/pw/pw_user.c | |
parent | 284e753ba98939b13927c8623439169ceb1a11e4 (diff) | |
download | FreeBSD-src-87175eabd73e5562787b2fe36328556a4f0df6a4.zip FreeBSD-src-87175eabd73e5562787b2fe36328556a4f0df6a4.tar.gz |
Fix a typo that prevented pw(8) from setting a user's UID to 0.
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
Diffstat (limited to 'usr.sbin/pw/pw_user.c')
-rw-r--r-- | usr.sbin/pw/pw_user.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/pw/pw_user.c b/usr.sbin/pw/pw_user.c index 30a2749..2f87b56 100644 --- a/usr.sbin/pw/pw_user.c +++ b/usr.sbin/pw/pw_user.c @@ -1654,7 +1654,7 @@ pw_user_mod(int argc, char **argv, char *arg1) } } - if (id > 0 && pwd->pw_uid != id) { + if (id >= 0 && pwd->pw_uid != id) { pwd->pw_uid = id; edited = true; if (pwd->pw_uid != 0 && strcmp(pwd->pw_name, "root") == 0) |