]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
[Fix] Fix dependencies id sanity check
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Sun, 7 Aug 2016 22:45:13 +0000 (23:45 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Sun, 7 Aug 2016 22:45:13 +0000 (23:45 +0100)
src/libserver/symbols_cache.c

index 02f45f522ee08147b9d53c4d4c8cbfb14a2dd752..bc91dce24ddec359e9bd704d52411f43327b6bc1 100644 (file)
@@ -1238,15 +1238,8 @@ rspamd_symbols_cache_check_deps (struct rspamd_task *task,
 
                        if (dep->item == NULL) {
                                /* Assume invalid deps as done */
-                               continue;
-                       }
-
-                       if (dep->id >= (gint)checkpoint->version) {
-                               /*
-                                * This is dependency on some symbol that is currently
-                                * not in this checkpoint. So we just pretend that the
-                                * corresponding symbold does not exist
-                                */
+                               msg_warn_task ("symbol %s has invalid dependencies from %s",
+                                               item->symbol, dep->sym);
                                continue;
                        }
 
@@ -1577,10 +1570,6 @@ rspamd_symbols_cache_process_symbols (struct rspamd_task * task,
                for (i = 0; i < (gint)checkpoint->waitq->len; i ++) {
                        item = g_ptr_array_index (checkpoint->waitq, i);
 
-                       if (item->id >= (gint)checkpoint->version) {
-                               continue;
-                       }
-
                        if (!isset (checkpoint->processed_bits, item->id * 2)) {
                                if (!rspamd_symbols_cache_check_deps (task, cache, item,
                                                checkpoint, 0)) {