diff options
author | Baptiste Daroussin <bapt@FreeBSD.org> | 2015-09-12 08:24:25 +0000 |
---|---|---|
committer | Baptiste Daroussin <bapt@FreeBSD.org> | 2015-09-12 08:24:25 +0000 |
commit | 9c04af5e0b95f4cebcc065c168ec58a4851b4764 (patch) | |
tree | fa0030a91d550ec0b5d66132ae082623c7e278a9 /pw/pw_user.c | |
parent | 88f0cfffc11ea9a3fa2d6ff0956b5ecadb3665f7 (diff) | |
download | pw-darwin-9c04af5e0b95f4cebcc065c168ec58a4851b4764.tar.gz pw-darwin-9c04af5e0b95f4cebcc065c168ec58a4851b4764.tar.zst pw-darwin-9c04af5e0b95f4cebcc065c168ec58a4851b4764.zip |
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
Diffstat (limited to 'pw/pw_user.c')
-rw-r--r-- | pw/pw_user.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/pw/pw_user.c b/pw/pw_user.c index 61d468a..f133147 100644 --- a/pw/pw_user.c +++ b/pw/pw_user.c @@ -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", |