]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
detect: Count buffer id once
authorJeff Lucovsky <jlucovsky@oisf.net>
Thu, 14 Sep 2023 14:29:17 +0000 (10:29 -0400)
committerVictor Julien <victor@inliniac.net>
Fri, 15 Sep 2023 15:09:00 +0000 (17:09 +0200)
This commit removes a second, unnecessary increment of the de_ctx buffer
id.

Issue: 5211

src/detect-engine.c

index 3810cb0a7af4c6058e83c7a50a51daebc76ad4ef..009741c503fbe1b8c0694d067dd18bf83d507fe5 100644 (file)
@@ -1893,7 +1893,6 @@ int DetectEngineBufferTypeGetByIdTransforms(
     BUG_ON(HashListTableAdd(de_ctx->buffer_type_hash_name, (void *)map, 0) != 0);
     BUG_ON(HashListTableAdd(de_ctx->buffer_type_hash_id, (void *)map, 0) != 0);
     SCLogDebug("buffer %s registered with id %d, parent %d", map->name, map->id, map->parent_id);
-    de_ctx->buffer_type_id++;
 
     if (map->frame) {
         DetectFrameInspectEngineCopy(de_ctx, map->parent_id, map->id, &map->transforms);