From 71c524b8bac5fa1ab313d9b1c28d71f48355b4b1 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Aleksey=20Kliger=20=28=CE=BBgeek=29?= Date: Wed, 13 Jul 2016 11:21:01 -0400 Subject: [PATCH] [logging] Default to stdout if MONO_LOG_DEST is unset (#3272) Follow up to e70a8aca1cd575582459db406ab3410e53074b73, do what the man page says and default to stdout if MONO_LOG_DEST isn't specified. --- mono/utils/mono-logger.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mono/utils/mono-logger.c b/mono/utils/mono-logger.c index 38c485212be..8c6c5aa5512 100644 --- a/mono/utils/mono-logger.c +++ b/mono/utils/mono-logger.c @@ -148,7 +148,7 @@ mono_trace_set_logdest_string (const char *dest) if(level_stack == NULL) mono_trace_init(); - if ((dest != NULL) && (strcmp("syslog", dest) != 0)) { + if ((dest == NULL) || (strcmp("syslog", dest) != 0)) { logger.opener = mono_log_open_logfile; logger.writer = mono_log_write_logfile; logger.closer = mono_log_close_logfile; -- 2.25.1