Regression: fix pw usermod -d
Mark the user has having been edited if -d option is passed to usermod and so the request change of home directory actually happen PR: 203052 Reported by: lenzi.sergio@gmail.com MFC after: 2 days
This commit is contained in:
parent
05081ecd11
commit
ec4f7bd978
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=287701
@ -1694,6 +1694,7 @@ pw_user_mod(int argc, char **argv, char *arg1)
|
||||
|
||||
if (homedir && strcmp(pwd->pw_dir, homedir) != 0) {
|
||||
pwd->pw_dir = homedir;
|
||||
edited = true;
|
||||
if (fstatat(conf.rootfd, pwd->pw_dir, &st, 0) == -1) {
|
||||
if (!createhome)
|
||||
warnx("WARNING: home `%s' does not exist",
|
||||
|
Loading…
Reference in New Issue
Block a user