]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] Do not stop symbols planning if async events are pending
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Tue, 14 Feb 2017 13:46:56 +0000 (13:46 +0000)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Tue, 14 Feb 2017 13:46:56 +0000 (13:46 +0000)
Issue: #1425

src/libserver/symbols_cache.c

index fe3e9fb4f86bf690e9c64c5d770a64b41d5ac7ae..03b60a2c231535ee6e48759f8de8113990265ecd 100644 (file)
@@ -1652,7 +1652,8 @@ rspamd_symbols_cache_process_symbols (struct rspamd_task * task,
                for (i = 0; i < (gint)checkpoint->version; i ++) {
                        item = g_ptr_array_index (checkpoint->order->d, i);
 
-                       if (!(item->type & SYMBOL_TYPE_FINE)) {
+                       if (!(item->type & SYMBOL_TYPE_FINE) &&
+                                       rspamd_session_events_pending (task->s) == 0) {
                                if (rspamd_symbols_cache_metric_limit (task, checkpoint)) {
                                        msg_info_task ("<%s> has already scored more than %.2f, so do "
                                                        "not "