From 80884002749013084a8fb68055d7f65771e8b8d4 Mon Sep 17 00:00:00 2001 From: Phillip Whelan Date: Thu, 10 Oct 2024 20:34:50 -0300 Subject: [PATCH] tests: internal: fix use-after-free for input_chunks test input_chunk_dropping_chunks. (#9472) Signed-off-by: Phillip Whelan --- tests/internal/input_chunk.c | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/tests/internal/input_chunk.c b/tests/internal/input_chunk.c index 2e2b5d04bef..945ddbbf13b 100644 --- a/tests/internal/input_chunk.c +++ b/tests/internal/input_chunk.c @@ -304,19 +304,6 @@ void flb_test_input_chunk_dropping_chunks() TEST_CHECK(ret == 0); } - /* FORCE clean up test tasks*/ - mk_list_foreach_safe(head, tmp, &i_ins->tasks) { - task = mk_list_entry(head, struct flb_task, _head); - flb_info("[task] cleanup test task"); - flb_task_destroy(task, FLB_TRUE); - } - - /* clean up test chunks */ - mk_list_foreach_safe(head, tmp, &i_ins->chunks) { - ic = mk_list_entry(head, struct flb_input_chunk, _head); - flb_input_chunk_destroy(ic, FLB_TRUE); - } - flb_time_msleep(2100); flb_stop(ctx); flb_destroy(ctx);