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
This commit is contained in:
parent
284e753ba9
commit
87175eabd7
@ -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)
|
||||
|
Loading…
Reference in New Issue
Block a user