aboutsummaryrefslogtreecommitdiffstats
path: root/log.c
diff options
context:
space:
mode:
Diffstat (limited to 'log.c')
-rw-r--r--log.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/log.c b/log.c
index f105ecd..91521c0 100644
--- a/log.c
+++ b/log.c
@@ -20,8 +20,11 @@
#include "pingu.h"
#include "log.h"
-void log_init(void)
+static int log_verbose = 0;
+
+void log_init(int verbose)
{
+ log_verbose = verbose;
openlog("pingu", LOG_PERROR | LOG_PID, LOG_DAEMON);
}
@@ -29,7 +32,7 @@ void log_debug(const char *format, ...)
{
va_list va;
- if (pingu_verbose) {
+ if (log_verbose) {
va_start(va, format);
vsyslog(LOG_DEBUG, format, va);
va_end(va);