test_utils: Make test headers appear in cyan
[nagios-reports-module.git] / logging.h
blob6df3b0aaf9b72c0aed973a8938a5dfed57eb5b43
1 #ifndef LOGGING_H
2 #define LOGGING_H
4 #include <stdarg.h>
6 #define ldebug logdebug
7 #define linfo loginfo
8 #define lwarn logwarn
9 #define lerr logerr
10 #define lmsg log_msg
12 #define SFLOG(s) sflog(s, __func__, __LINE__);
14 extern int log_init(void);
15 void log_deinit(void);
16 int log_grok_var(char *var, char *val);
17 void loginfo(const char *fmt, ...)
18 __attribute__((__format__(__printf__, 1, 2)));
19 void logwarn(const char *fmt, ...)
20 __attribute__((__format__(__printf__, 1, 2)));
21 void logerr(const char *fmt, ...)
22 __attribute__((__format__(__printf__, 1, 2)));
23 void logdebug(const char *fmt, ...)
24 __attribute__((__format__(__printf__, 1, 2)));
25 void log_msg(int level, const char *fmt, ...)
26 __attribute__((__format__(__printf__, 2, 3)));
27 int sflog(const char *syscall, const char *func, int line);
29 #endif