]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
Minor fix for detection engine setup error check
authorVictor Julien <victor@inliniac.net>
Thu, 17 Oct 2013 15:41:52 +0000 (17:41 +0200)
committerVictor Julien <victor@inliniac.net>
Thu, 17 Oct 2013 15:41:52 +0000 (17:41 +0200)
cppcheck said:
[detect-engine-mpm.c:2075] -> [detect-engine-mpm.c:2075]: (style) Same expression on both sides of '||'.

src/detect-engine-mpm.c

index 62c0de7f0f22a7a2eb0fa6e23cdf01af15dd00a0..dfbc947428b640db0b3359ecc6d04a83f32941bd 100644 (file)
@@ -2072,7 +2072,7 @@ int PatternMatchPrepareGroup(DetectEngineCtx *de_ctx, SigGroupHead *sh)
             sh->mpm_stream_ctx_ts = MpmFactoryGetMpmCtxForProfile(de_ctx, MPM_CTX_FACTORY_UNIQUE_CONTEXT, 0);
             sh->mpm_stream_ctx_tc = MpmFactoryGetMpmCtxForProfile(de_ctx, MPM_CTX_FACTORY_UNIQUE_CONTEXT, 1);
         }
-        if (sh->mpm_stream_ctx_tc == NULL || sh->mpm_stream_ctx_tc == NULL) {
+        if (sh->mpm_stream_ctx_tc == NULL || sh->mpm_stream_ctx_ts == NULL) {
             SCLogDebug("sh->mpm_stream_ctx == NULL. This should never happen");
             exit(EXIT_FAILURE);
         }