summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2018-02-06 14:47:48 +0100
committerThomas Haller <thaller@redhat.com>2018-02-07 13:41:52 +0100
commite6f15f26ebdc0d75e3e121bd6eb4b400c21394a6 (patch)
tree120eb46e78909ba9139aa5751031aa8a15ea5b59 /src
parent8b4f119272a474ba5c9fbbd6f3e212dd4169194d (diff)
core/logging: with --debug also output glib messages in stderr
With --debug, we duplicate nm-log messages to stderr. Do the same for glib messages and don't only send them to syslog/journal.
Diffstat (limited to 'src')
-rw-r--r--src/nm-logging.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/nm-logging.c b/src/nm-logging.c
index 4ef786f6e9..11e05c31f7 100644
--- a/src/nm-logging.c
+++ b/src/nm-logging.c
@@ -768,6 +768,9 @@ nm_log_handler (const gchar *log_domain,
break;
}
+ if (global.debug_stderr)
+ g_printerr ("%s%s\n", global.prefix, message ?: "");
+
switch (global.log_backend) {
#if SYSTEMD_JOURNAL
case LOG_BACKEND_JOURNAL: