]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
mpm/hs: improve pointer hygene
authorVictor Julien <vjulien@oisf.net>
Fri, 29 Dec 2023 09:59:43 +0000 (10:59 +0100)
committerVictor Julien <victor@inliniac.net>
Mon, 8 Jan 2024 19:23:28 +0000 (20:23 +0100)
src/util-mpm-hs.c

index f1594434ff8ee06810fd154017a2fe0b184e377f..5c241991842e645aaa105e50483a6aa21845b3b8 100644 (file)
@@ -873,6 +873,7 @@ void SCHSDestroyCtx(MpmCtx *mpm_ctx)
     SCMutexUnlock(&g_db_table_mutex);
 
     SCFree(mpm_ctx->ctx);
+    mpm_ctx->ctx = NULL;
     mpm_ctx->memory_cnt--;
     mpm_ctx->memory_size -= sizeof(SCHSCtx);
 }