summaryrefslogtreecommitdiffstats
path: root/workspace/customdhcpcd/src/logger.c
diff options
context:
space:
mode:
authorNiklas2011-07-21 17:29:53 +0200
committerNiklas2011-07-21 17:29:53 +0200
commitddac93a94b860c94e6fb893ed5a9c508c19231f1 (patch)
treefc37d45829e2d94f9fbcfe08531fdb3a10750009 /workspace/customdhcpcd/src/logger.c
parentconfiguration of more than one interface is working. Both progressbars are up... (diff)
downloadfbgui-ddac93a94b860c94e6fb893ed5a9c508c19231f1.tar.gz
fbgui-ddac93a94b860c94e6fb893ed5a9c508c19231f1.tar.xz
fbgui-ddac93a94b860c94e6fb893ed5a9c508c19231f1.zip
log messages are delivered to qt app.
Diffstat (limited to 'workspace/customdhcpcd/src/logger.c')
-rw-r--r--workspace/customdhcpcd/src/logger.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/workspace/customdhcpcd/src/logger.c b/workspace/customdhcpcd/src/logger.c
index d084e62..cecd2b8 100644
--- a/workspace/customdhcpcd/src/logger.c
+++ b/workspace/customdhcpcd/src/logger.c
@@ -42,6 +42,7 @@
#include "common.h"
#include "logger.h"
+#include "logwriter.h"
static int loglevel = LOG_WARNING;
@@ -97,6 +98,12 @@ void logger (int level, const char *fmt, ...)
vfprintf (f, fmt, p);
fputc ('\n', f);
+ /* new function by Niklas Goby
+ * send the log message also to our Qt programm.
+ * implemented in logwriter.c
+ * */
+ logLoggerToQt(level, fmt, p);
+
/* stdout, stderr may be re-directed to some kind of buffer.
* So we always flush to ensure it's written. */
fflush (f);