Merge pull request #296 from ikerexxe/log_exit_code

useradd: log exit code when failing
This commit is contained in:
Serge Hallyn 2020-12-27 00:18:12 -06:00 committed by GitHub
commit a8361e7410
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -338,7 +338,7 @@ static void fail_exit (int code)
user_name, AUDIT_NO_ID, user_name, AUDIT_NO_ID,
SHADOW_AUDIT_FAILURE); SHADOW_AUDIT_FAILURE);
#endif #endif
SYSLOG ((LOG_INFO, "failed adding user '%s', data deleted", user_name)); SYSLOG ((LOG_INFO, "failed adding user '%s', exit code: %d", user_name, code));
exit (code); exit (code);
} }