diff options
author | bapt <bapt@FreeBSD.org> | 2015-09-14 05:37:32 +0000 |
---|---|---|
committer | bapt <bapt@FreeBSD.org> | 2015-09-14 05:37:32 +0000 |
commit | 95285c2f6de264d18e28b5b0cd636a1708dd4b75 (patch) | |
tree | 2ef43ff2b255d1debda6a85223e193778f5c6e1b /usr.sbin | |
parent | bc3c6d9c811a33f3915a77326c82c00f9909f43e (diff) | |
download | FreeBSD-src-95285c2f6de264d18e28b5b0cd636a1708dd4b75.zip FreeBSD-src-95285c2f6de264d18e28b5b0cd636a1708dd4b75.tar.gz |
MFC: r287701
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
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/pw/pw_user.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/usr.sbin/pw/pw_user.c b/usr.sbin/pw/pw_user.c index 61d468a..f133147 100644 --- a/usr.sbin/pw/pw_user.c +++ b/usr.sbin/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", |