From: Todd C. Miller Date: Tue, 21 Sep 2010 11:56:36 +0000 (-0400) Subject: Ignore ECONNREFUSED from audit_log_user_command() which will X-Git-Tag: SUDO_1_7_5~144 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=8ac95119a37c6014e937959e629ba721a29cb941;p=sudo Ignore ECONNREFUSED from audit_log_user_command() which will occur if auditd is not running. --HG-- branch : 1.7 --- diff --git a/linux_audit.c b/linux_audit.c index dabf6b33a..16e21af1b 100644 --- a/linux_audit.c +++ b/linux_audit.c @@ -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);