From: Vsevolod Stakhov Date: Tue, 28 Feb 2017 13:01:01 +0000 (+0000) Subject: [Minor] Fix enabled checks for symbols in cache X-Git-Tag: 1.5.0~14 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=10e5fd4ebd63218d23a4bbb52e4706e38caaff2a;p=rspamd.git [Minor] Fix enabled checks for symbols in cache --- diff --git a/src/libserver/symbols_cache.c b/src/libserver/symbols_cache.c index cf0161945..59b0ab5d6 100644 --- a/src/libserver/symbols_cache.c +++ b/src/libserver/symbols_cache.c @@ -1023,6 +1023,7 @@ rspamd_symbols_cache_validate_cb (gpointer k, gpointer v, gpointer ud) msg_info_cache ("adding unknown symbol %s to metric %s", item->symbol, m->name); + ghost = FALSE; } cur = g_list_next (cur); @@ -2391,7 +2392,7 @@ rspamd_symbols_cache_is_symbol_enabled (struct rspamd_task *task, if (checkpoint) { if (isset (checkpoint->processed_bits, id * 2)) { - return FALSE; + ret = FALSE; } else { if (item->condition_cb != -1) { @@ -2412,10 +2413,8 @@ rspamd_symbols_cache_is_symbol_enabled (struct rspamd_task *task, lua_pop (L, 1); } } - - return ret; } } - return FALSE; + return ret; }