summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2013-12-18 05:09:53 +0100
committerLennart Poettering <lennart@poettering.net>2013-12-18 18:21:27 +0100
commit220ec97ad65150542bb9c8a1ba20b19ea0d49ff8 (patch)
treeef0d3665c34ec01a17095187d93eba3407cc87a8
parent99f098257f5e4135609edc3df965ebf27975df18 (diff)
core: in a container log to /dev/console if "debug" is specified
-rw-r--r--src/core/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/main.c b/src/core/main.c
index e00d0702fe..eac4fe6134 100644
--- a/src/core/main.c
+++ b/src/core/main.c
@@ -417,7 +417,7 @@ static int parse_proc_cmdline_word(const char *word) {
* will block with every log message for for 60 seconds,
* before they give up. */
log_set_max_level(LOG_DEBUG);
- log_set_target(LOG_TARGET_KMSG);
+ log_set_target(detect_container(NULL) > 0 ? LOG_TARGET_CONSOLE : LOG_TARGET_KMSG);
} else if (!in_initrd()) {
unsigned i;