From f6fd1b017fdb051ecbb028971648e990d3295c2c Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Sat, 28 Jan 2023 10:09:30 +0100 Subject: [PATCH] detect/dce.stub_data: update buffer initialization logic --- src/detect-dce-stub-data.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/detect-dce-stub-data.c b/src/detect-dce-stub-data.c index 6a4f540885..a05d91d271 100644 --- a/src/detect-dce-stub-data.c +++ b/src/detect-dce-stub-data.c @@ -72,7 +72,7 @@ static InspectionBuffer *GetSMBData(DetectEngineThreadCtx *det_ctx, void *txv, const int list_id) { InspectionBuffer *buffer = InspectionBufferGet(det_ctx, list_id); - if (buffer->inspect == NULL) { + if (!buffer->initialized) { uint32_t data_len = 0; const uint8_t *data = NULL; uint8_t dir = flow_flags & (STREAM_TOSERVER|STREAM_TOCLIENT); @@ -92,7 +92,7 @@ static InspectionBuffer *GetDCEData(DetectEngineThreadCtx *det_ctx, void *txv, const int list_id) { InspectionBuffer *buffer = InspectionBufferGet(det_ctx, list_id); - if (buffer->inspect == NULL) { + if (!buffer->initialized) { uint32_t data_len = 0; const uint8_t *data = NULL; uint8_t endianness; -- 2.47.2