aboutsummaryrefslogtreecommitdiffstats
path: root/src/libserver/cfg_rcl.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libserver/cfg_rcl.c')
-rw-r--r--src/libserver/cfg_rcl.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/libserver/cfg_rcl.c b/src/libserver/cfg_rcl.c
index f50b37010..57674aae3 100644
--- a/src/libserver/cfg_rcl.c
+++ b/src/libserver/cfg_rcl.c
@@ -31,6 +31,15 @@
#include "expression.h"
#include "composites.h"
#include "libserver/worker_util.h"
+#include "unix-std.h"
+
+#ifdef HAVE_SYSLOG_H
+#include <syslog.h>
+#endif
+
+#ifdef HAVE_GLOB_H
+#include <glob.h>
+#endif
struct rspamd_rcl_default_handler_data {
struct rspamd_rcl_struct_parser pd;
@@ -103,6 +112,7 @@ rspamd_rcl_logging_handler (rspamd_mempool_t *pool, const ucl_object_t *obj,
}
else if (g_ascii_strcasecmp (log_type, "syslog") == 0) {
/* Need to get facility */
+#ifdef HAVE_SYSLOG_H
cfg->log_facility = LOG_DAEMON;
cfg->log_type = RSPAMD_LOG_SYSLOG;
val = ucl_object_find_key (obj, "facility");
@@ -168,6 +178,7 @@ rspamd_rcl_logging_handler (rspamd_mempool_t *pool, const ucl_object_t *obj,
return FALSE;
}
}
+#endif
}
else if (g_ascii_strcasecmp (log_type,
"stderr") == 0 || g_ascii_strcasecmp (log_type, "console") == 0) {