From: Victor Julien Date: Fri, 10 Sep 2021 08:19:50 +0000 (+0200) Subject: detect: remove dead code X-Git-Tag: suricata-5.0.8~29 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1aa4fc13cbe37530b11d8f7b787189c964ecef6d;p=thirdparty%2Fsuricata.git detect: remove dead code (cherry picked from commit ae89874b066c91675b809e8cf992d780331efb1c) --- diff --git a/src/detect.c b/src/detect.c index face274c1e..3c4f3d709a 100644 --- a/src/detect.c +++ b/src/detect.c @@ -744,7 +744,6 @@ static inline void DetectRulePacketRules( while (match_cnt--) { RULE_PROFILING_START(p); uint8_t alert_flags = 0; - bool state_alert = false; #ifdef PROFILING bool smatch = false; /* signature match */ #endif @@ -806,9 +805,7 @@ static inline void DetectRulePacketRules( DetectRunPostMatch(tv, det_ctx, p, s); if (!(sflags & SIG_FLAG_NOALERT)) { - /* stateful sigs call PacketAlertAppend from DeStateDetectStartDetection */ - if (!state_alert) - PacketAlertAppend(det_ctx, s, p, 0, alert_flags); + PacketAlertAppend(det_ctx, s, p, 0, alert_flags); } else { /* apply actions even if not alerting */ DetectSignatureApplyActions(p, s, alert_flags);