From 66340be0729d18f722cc3b18f926f6fe7ee90bbf Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Fri, 24 Sep 2010 14:57:10 +0200 Subject: [PATCH] Fix pcre compilation with debug enabled. --- src/detect-pcre.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/detect-pcre.c b/src/detect-pcre.c index ff5b6af257..4b896d8de3 100644 --- a/src/detect-pcre.c +++ b/src/detect-pcre.c @@ -266,7 +266,7 @@ int DetectPcreALDoMatchMethod(DetectEngineThreadCtx *det_ctx, Signature *s, /* run the actual pcre detection */ ret = pcre_exec(pe->re, pe->sd, (char *)ptr, len, 0, 0, ov, MAX_SUBSTRINGS); - SCLogDebug("ret %d (negating %s)", ret, pe->negate ? "set" : "not set"); + SCLogDebug("ret %d (negating %s)", ret, (pe->flags & DETECT_PCRE_NEGATE) ? "set" : "not set"); if (ret == PCRE_ERROR_NOMATCH) { if (pe->flags & DETECT_PCRE_NEGATE) { @@ -383,7 +383,7 @@ int DetectPcreALDoMatchHeader(DetectEngineThreadCtx *det_ctx, Signature *s, /* run the actual pcre detection */ ret = pcre_exec(pe->re, pe->sd, (char *)ptr, len, 0, 0, ov, MAX_SUBSTRINGS); - SCLogDebug("ret %d (negating %s)", ret, pe->negate ? "set" : "not set"); + SCLogDebug("ret %d (negating %s)", ret, (pe->flags & DETECT_PCRE_NEGATE) ? "set" : "not set"); if (ret == PCRE_ERROR_NOMATCH) { if (pe->flags & DETECT_PCRE_NEGATE) { @@ -502,7 +502,7 @@ int DetectPcreALDoMatchCookie(DetectEngineThreadCtx *det_ctx, Signature *s, /* run the actual pcre detection */ ret = pcre_exec(pe->re, pe->sd, (char *)ptr, len, 0, 0, ov, MAX_SUBSTRINGS); - SCLogDebug("ret %d (negating %s)", ret, pe->negate ? "set" : "not set"); + SCLogDebug("ret %d (negating %s)", ret, (pe->flags & DETECT_PCRE_NEGATE) ? "set" : "not set"); if (ret == PCRE_ERROR_NOMATCH) { if (pe->flags & DETECT_PCRE_NEGATE) { @@ -764,7 +764,7 @@ int DetectPcrePayloadMatch(DetectEngineThreadCtx *det_ctx, Signature *s, /* run the actual pcre detection */ ret = pcre_exec(pe->re, pe->sd, (char *)ptr, len, 0, 0, ov, MAX_SUBSTRINGS); - SCLogDebug("ret %d (negating %s)", ret, pe->negate ? "set" : "not set"); + SCLogDebug("ret %d (negating %s)", ret, (pe->flags & DETECT_PCRE_NEGATE) ? "set" : "not set"); if (ret == PCRE_ERROR_NOMATCH) { if (pe->flags & DETECT_PCRE_NEGATE) { @@ -858,7 +858,7 @@ int DetectPcrePacketPayloadMatch(DetectEngineThreadCtx *det_ctx, Packet *p, Sign /* run the actual pcre detection */ ret = pcre_exec(pe->re, pe->sd, (char *)ptr, len, 0, 0, ov, MAX_SUBSTRINGS); - SCLogDebug("ret %d (negating %s)", ret, pe->negate ? "set" : "not set"); + SCLogDebug("ret %d (negating %s)", ret, (pe->flags & DETECT_PCRE_NEGATE) ? "set" : "not set"); if (ret == PCRE_ERROR_NOMATCH) { if (pe->flags & DETECT_PCRE_NEGATE) { @@ -951,7 +951,7 @@ int DetectPcrePayloadDoMatch(DetectEngineThreadCtx *det_ctx, Signature *s, /* run the actual pcre detection */ ret = pcre_exec(pe->re, pe->sd, (char *)ptr, len, 0, 0, ov, MAX_SUBSTRINGS); - SCLogDebug("ret %d (negating %s)", ret, pe->negate ? "set" : "not set"); + SCLogDebug("ret %d (negating %s)", ret, (pe->flags & DETECT_PCRE_NEGATE) ? "set" : "not set"); if (ret == PCRE_ERROR_NOMATCH) { if (pe->flags & DETECT_PCRE_NEGATE) {