mirror of
https://github.com/morgan9e/systemd
synced 2026-04-15 08:56:15 +09:00
pam-util: fix pam_syslog_errno() ignoring the level parameter
The function accepts a level parameter but was always logging at LOG_ERR. Fix by passing the level parameter to sym_pam_vsyslog() instead of hardcoding LOG_ERR. This caused debug and warning messages to incorrectly appear in error logs.
This commit is contained in:
@@ -75,7 +75,7 @@ int pam_syslog_errno(pam_handle_t *handle, int level, int error, const char *for
|
||||
LOCAL_ERRNO(error);
|
||||
|
||||
va_start(ap, format);
|
||||
sym_pam_vsyslog(handle, LOG_ERR, format, ap);
|
||||
sym_pam_vsyslog(handle, level, format, ap);
|
||||
va_end(ap);
|
||||
|
||||
return error == -ENOMEM ? PAM_BUF_ERR : PAM_SERVICE_ERR;
|
||||
|
||||
Reference in New Issue
Block a user