* src/useradd.c: When exiting because of a failure, warn if an
home directory created, but cannot be removed.
This commit is contained in:
parent
86498400da
commit
8e2010a26c
@ -1,3 +1,8 @@
|
||||
2010-03-18 Nicolas François <nicolas.francois@centraliens.net>
|
||||
|
||||
* src/useradd.c: When exiting because of a failure, warn if an
|
||||
home directory created, but cannot be removed.
|
||||
|
||||
2010-03-18 Nicolas François <nicolas.francois@centraliens.net>
|
||||
|
||||
* libmisc/chowndir.c: Re-indent.
|
||||
|
@ -208,7 +208,12 @@ static void create_mail (void);
|
||||
static void fail_exit (int code)
|
||||
{
|
||||
if (home_added) {
|
||||
rmdir (user_home);
|
||||
if (rmdir (user_home) != 0) {
|
||||
frpintf (stderr,
|
||||
_("%s: %s was created, but could not be removed\n"),
|
||||
Prog, user_home);
|
||||
SYSLOG ((LOG_ERR, "failed to remove %s", user_home));
|
||||
}
|
||||
}
|
||||
|
||||
if (spw_locked) {
|
||||
|
Loading…
Reference in New Issue
Block a user