From bd198231a0518427bfc2ca2639aceb8d3efc164b Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Sun, 24 May 2026 20:50:39 +0200 Subject: [PATCH] util/port-interval-tree: suppress cppcheck false positives --- src/util-port-interval-tree.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/util-port-interval-tree.c b/src/util-port-interval-tree.c index e45a55eb23..b38e2ff7fc 100644 --- a/src/util-port-interval-tree.c +++ b/src/util-port-interval-tree.c @@ -38,6 +38,7 @@ */ static int SCPortIntervalCompareAndUpdate(const SCPortIntervalNode *a, SCPortIntervalNode *b) { + DEBUG_VALIDATE_BUG_ON(a == NULL); // help cppcheck if (a->port2 > b->max) { b->max = a->port2; } @@ -48,6 +49,7 @@ static int SCPortIntervalCompareAndUpdate(const SCPortIntervalNode *a, SCPortInt } // cppcheck-suppress nullPointerRedundantCheck +// cppcheck-suppress ctunullpointer IRB_GENERATE(PI, SCPortIntervalNode, irb, SCPortIntervalCompareAndUpdate); /**