summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 17d5fce)
raw | patch | inline | side by side (parent: 17d5fce)
author | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Mon, 22 Mar 2010 14:51:06 +0000 (14:51 +0000) | ||
committer | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Mon, 22 Mar 2010 14:51:06 +0000 (14:51 +0000) |
src/rrd_daemon.c | patch | blob | history |
diff --git a/src/rrd_daemon.c b/src/rrd_daemon.c
index ba9c2adfa979cf955bd1858507b442af01ed2b3a..154f0dee366bff3208a5a1ba9b6cc2d20664202c 100644 (file)
--- a/src/rrd_daemon.c
+++ b/src/rrd_daemon.c
#include <glib-2.0/glib.h>
/* }}} */
-#define RRDD_LOG(severity, ...) syslog ((severity), __VA_ARGS__)
+#define RRDD_LOG(severity, ...) \
+ do { \
+ if (stay_foreground) \
+ fprintf(stderr, __VA_ARGS__); \
+ syslog ((severity), __VA_ARGS__); \
+ } while (0)
#ifndef __GNUC__
# define __attribute__(x) /**/