From 27f67dcad009296bdd26d30d178b9ae3c9c8443c Mon Sep 17 00:00:00 2001 From: nekral-guest Date: Thu, 18 Mar 2010 10:52:52 +0000 Subject: [PATCH] * src/pwck.c: Unlock the password and shadow files when there is a failure to prepare the update in memory. --- ChangeLog | 5 +++++ src/pwck.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 2e0df528..56add6ae 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2010-03-18 Nicolas François + + * src/pwck.c: Unlock the password and shadow files when there is a + failure to prepare the update in memory. + 2010-03-18 Nicolas François * src/pwck.c: Only log to SYSLOG when acting on system files. diff --git a/src/pwck.c b/src/pwck.c index dafa5819..316797f1 100644 --- a/src/pwck.c +++ b/src/pwck.c @@ -590,7 +590,7 @@ static void check_pw_file (int *errors, bool *changed) fprintf (stderr, _("%s: failed to prepare the new %s entry '%s'\n"), Prog, spw_dbname (), sp.sp_namp); - exit (E_CANTUPDATE); + fail_exit (E_CANTUPDATE); } /* remove password from /etc/passwd */ pw = *pwd;