From 22555b58ec10e654bab69b94597132fea1b13394 Mon Sep 17 00:00:00 2001 From: z3APA3A <3APA3A@3proxy.ru> Date: Thu, 15 Oct 2020 16:00:43 +0300 Subject: [PATCH] Do not sigmask main thread for standalone services --- src/proxymain.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/proxymain.c b/src/proxymain.c index 7844c84..afdf362 100644 --- a/src/proxymain.c +++ b/src/proxymain.c @@ -286,11 +286,6 @@ int MODULEMAINFUNC (int argc, char** argv){ srv.next = conf.services; conf.services = conf.services->prev = &srv; } -#else - srv.needuser = 0; - pthread_mutex_init(&log_mutex, NULL); -#endif - #ifndef _WIN32 { sigset_t mask; @@ -298,6 +293,10 @@ int MODULEMAINFUNC (int argc, char** argv){ pthread_sigmask(SIG_SETMASK, &mask, NULL); } #endif +#else + srv.needuser = 0; + pthread_mutex_init(&log_mutex, NULL); +#endif for (i=1; i