Ignore ECONNREFUSED from audit_log_user_command() which will

occur if auditd is not running.
This commit is contained in:
Todd C. Miller
2010-09-21 07:56:16 -04:00
parent 89f161ad8e
commit 590eed3bd7

View File

@@ -81,9 +81,9 @@ linux_audit_command(char *argv[], int result)
}
*--cp = '\0';
/* Log command, ignoring EPERM on error. */
/* Log command, ignoring ECONNREFUSED on error. */
rc = audit_log_user_command(au_fd, AUDIT_USER_CMD, command, NULL, result);
if (rc <= 0)
if (rc <= 0 && errno != ECONNREFUSED)
warning("unable to send audit message");
efree(command);