From: Vsevolod Stakhov Date: Mon, 14 May 2018 16:44:41 +0000 (+0100) Subject: [Fix] Do not open sockets for disabled workers X-Git-Tag: 1.7.5~28 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=b4ec4142b790eedc7d8e8ddb5e6457e63c425301;p=rspamd.git [Fix] Do not open sockets for disabled workers --- diff --git a/src/rspamd.c b/src/rspamd.c index c22afe861..ab065a967 100644 --- a/src/rspamd.c +++ b/src/rspamd.c @@ -557,7 +557,7 @@ spawn_workers (struct rspamd_main *rspamd_main, struct event_base *ev_base) msg_err_main ("type of worker is unspecified, skip spawning"); } else { - if (!cf->enabled) { + if (!cf->enabled || cf->count <= 0) { msg_info_main ("worker of type %s is disabled in the config, " "skip spawning", g_quark_to_string (cf->type)); cur = g_list_next (cur);