* src/groupmems.c: Check the return value of gr_update().
* src/chage.c, src/chfn.c, src/chgpasswd.c, src/chpasswd.c, src/chsh.c, src/gpasswd.c, src/groupadd.c, src/groupmems.c, src/groupmod.c, src/grpck.c, src/grpconv.c, src/grpunconv.c, src/passwd.c, src/pwck.c, src/pwconv.c, src/pwunconv.c, src/useradd.c, src/userdel.c, src/usermod.c: Harmonize the error message sent to stderr in case of *_update () failure. * src/chage.c, src/chsh.c, src/groupadd.c, src/passwd.c: Do not log to syslog when pw_update() or spw_update() fail. * src/newusers.c: Do not log specific error message to stderr when sgr_update() fails. * src/pwconv.c: Remove duplicated definition of Prog.
This commit is contained in:
10
src/grpck.c
10
src/grpck.c
@ -592,9 +592,8 @@ static void check_grp_file (int *errors, bool *changed)
|
||||
|
||||
if (sgr_update (&sg) == 0) {
|
||||
fprintf (stderr,
|
||||
_
|
||||
("%s: can't update shadow entry for %s\n"),
|
||||
Prog, sg.sg_name);
|
||||
_("%s: failed to prepare the new %s entry '%s'\n"),
|
||||
Prog, sgr_dbname (), sg.sg_name);
|
||||
fail_exit (E_CANT_UPDATE);
|
||||
}
|
||||
/* remove password from /etc/group */
|
||||
@ -602,9 +601,8 @@ static void check_grp_file (int *errors, bool *changed)
|
||||
gr.gr_passwd = SHADOW_PASSWD_STRING; /* XXX warning: const */
|
||||
if (gr_update (&gr) == 0) {
|
||||
fprintf (stderr,
|
||||
_
|
||||
("%s: can't update entry for group %s\n"),
|
||||
Prog, gr.gr_name);
|
||||
_("%s: failed to prepare the new %s entry '%s'\n"),
|
||||
Prog, gr_dbname (), gr.gr_name);
|
||||
fail_exit (E_CANT_UPDATE);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user