]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
[Minor] Fix double free in fuzzy storage
authorVsevolod Stakhov <vsevolod@rspamd.com>
Wed, 29 Oct 2025 10:19:18 +0000 (10:19 +0000)
committerVsevolod Stakhov <vsevolod@rspamd.com>
Wed, 29 Oct 2025 10:19:18 +0000 (10:19 +0000)
src/fuzzy_storage.c

index 0782dcb1e9ea1eb73c5506d4bf384316353ea6c7..1f8cccef24d2a97bc1e793130e2f89c04f24dd39 100644 (file)
@@ -4459,13 +4459,7 @@ start_fuzzy(struct rspamd_worker *worker)
                g_free(cur);
        }
 
-       if (ctx->default_forbidden_ids) {
-               kh_destroy(fuzzy_key_ids_set, ctx->default_forbidden_ids);
-       }
-
-       if (ctx->weak_ids) {
-               kh_destroy(fuzzy_key_ids_set, ctx->weak_ids);
-       }
+       /* default_forbidden_ids and weak_ids are freed by mempool destructor */
 
        CFG_REF_RELEASE(ctx->cfg);
        CFG_REF_RELEASE(ctx->cfg);