From b4e6bbe4bcd3fda31532a2bba138af81bb53760b Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Mon, 9 Dec 2013 13:29:02 +0100 Subject: [PATCH] flowvar: initialize new memory to prevent issues on error handling --- src/detect-flowvar.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/detect-flowvar.c b/src/detect-flowvar.c index 1f5bdc1aff..aa630b61a1 100644 --- a/src/detect-flowvar.c +++ b/src/detect-flowvar.c @@ -173,6 +173,7 @@ static int DetectFlowvarSetup (DetectEngineCtx *de_ctx, Signature *s, char *raws fd = SCMalloc(sizeof(DetectFlowvarData)); if (unlikely(fd == NULL)) goto error; + memset(fd, 0x00, sizeof(*fd)); fd->content = SCMalloc(contentlen); if (unlikely(fd->content == NULL))