From bc3442ba29d83c1ffd566a9a612ec89146eba9b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Mierzwa?= Date: Sun, 6 Apr 2014 14:43:22 +0200 Subject: [PATCH] uwsgi_setup_log_master must always be called after logto(), this was not happening with --logto2 --- core/uwsgi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/uwsgi.c b/core/uwsgi.c index 4ff6e31e..76631ab6 100644 --- a/core/uwsgi.c +++ b/core/uwsgi.c @@ -2198,7 +2198,7 @@ void uwsgi_setup(int argc, char *argv[], char *envp[]) { uwsgi_opt_flock(NULL, uwsgi.flock_wait2, NULL); // setup master logging - if (uwsgi.log_master && !uwsgi.daemonize2) + if (uwsgi.log_master && !uwsgi.daemonize2 && !uwsgi.logto2) uwsgi_setup_log_master(); // setup offload engines @@ -2481,6 +2481,7 @@ int uwsgi_start(void *v_argv) { if (uwsgi.logto2) { if (!uwsgi.is_a_reload || uwsgi.log_reopen) { logto(uwsgi.logto2); + uwsgi_setup_log_master(); } }