From d22586d60e6708b9addf1139d8733bdadde64c15 Mon Sep 17 00:00:00 2001 From: Baptiste Daroussin Date: Fri, 14 Aug 2015 13:39:55 +0000 Subject: Regression: fix pw usermod -w xxx Reported by: gjb --- pw/pw_user.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pw/pw_user.c b/pw/pw_user.c index d9bce87..5ccbd53 100644 --- a/pw/pw_user.c +++ b/pw/pw_user.c @@ -1645,6 +1645,8 @@ pw_user_mod(int argc, char **argv, char *arg1) if (lc == NULL || login_setcryptfmt(lc, "sha512", NULL) == NULL) warn("setting crypt(3) format"); login_close(lc); + cnf->default_password = boolean_val(passwd, + cnf->default_password); pwd->pw_passwd = pw_password(cnf, pwd->pw_name, dryrun); edited = true; } -- cgit v1.2.3-56-ge451