diff options
author | Joe Orton <jorton@apache.org> | 2012-05-31 15:22:02 +0200 |
---|---|---|
committer | Joe Orton <jorton@apache.org> | 2012-05-31 15:22:02 +0200 |
commit | 63b24c308910daaa66d5f32638a3bb8b956333e5 (patch) | |
tree | 1313b953fdbf1a855faf125f34a4ac489d7cfd9a /support | |
parent | xforms (diff) | |
download | apache2-63b24c308910daaa66d5f32638a3bb8b956333e5.tar.xz apache2-63b24c308910daaa66d5f32638a3bb8b956333e5.zip |
* support/suexec.c: Define AP_LOG_FACILITY.
(err_output): Use AP_LOG_FACILITY for syslog facility.
Suggested by: kbrand
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1344712 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'support')
-rw-r--r-- | support/suexec.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/support/suexec.c b/support/suexec.c index 8d7fcfdd99..5b6b254cc8 100644 --- a/support/suexec.c +++ b/support/suexec.c @@ -75,8 +75,16 @@ extern char **environ; #ifdef AP_LOG_SYSLOG +/* Syslog support. */ +#if !defined(AP_LOG_FACILITY) && defined(LOG_AUTHPRIV) +#define AP_LOG_FACILITY LOG_AUTHPRIV +#elif !defined(AP_LOG_FACILITY) +#define AP_LOG_FACILITY LOG_AUTH +#endif + static int log_open; #else +/* Non-syslog support. */ static FILE *log = NULL; #endif @@ -148,7 +156,7 @@ static void err_output(int is_error, const char *fmt, va_list ap) { #if defined(AP_LOG_SYSLOG) if (!log_open) { - openlog("suexec", LOG_PID, LOG_DAEMON); + openlog("suexec", LOG_PID, AP_LOG_FACILITY); log_open = 1; } |