sinkserver/sink/logging.c

18 lines
303 B
C
Raw Normal View History

2021-02-09 18:48:50 +01:00
#define _DEFAULT_SOURCE
2021-02-09 18:47:20 +01:00
2021-02-09 18:32:58 +01:00
#include <syslog.h>
#include <stdarg.h>
2021-02-09 18:53:32 +01:00
#include <stdio.h>
2021-02-09 18:32:58 +01:00
void logmsg(int prio, const char* format, ...) {
va_list vl;
2021-02-09 18:53:32 +01:00
// openlog("counter", 0, LOG_LOCAL0);
2021-02-09 18:32:58 +01:00
va_start(vl, format);
2021-02-09 18:53:32 +01:00
//vsyslog(prio, format, vl);
2021-02-09 18:54:08 +01:00
vprintf(format, vl);
2021-02-09 18:32:58 +01:00
va_end(vl);
2021-02-09 18:53:32 +01:00
// closelog();
2021-02-09 18:32:58 +01:00
}