This is an automated email from the ASF dual-hosted git repository.
bcall pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/master by this push:
new 50bad7339d Fix memory leak in ink_event_system_init (#12065)
50bad7339d is described below
commit 50bad7339db50d482cb01b2b101504230b80cd21
Author: Hiroaki Nakamura <[email protected]>
AuthorDate: Tue Mar 4 08:10:55 2025 +0900
Fix memory leak in ink_event_system_init (#12065)
The memory for chunk_sizes_string is allocated in
REC_ConfigReadString
RecGetRecordString_Xmalloc
RecGetRecord_Xmalloc
RecDataSet
ats_strdup
_xstrdup
ats_malloc
So it must be freed with ats_free.
---
src/iocore/eventsystem/EventSystem.cc | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/iocore/eventsystem/EventSystem.cc
b/src/iocore/eventsystem/EventSystem.cc
index f37b178bb0..6aad9c38e5 100644
--- a/src/iocore/eventsystem/EventSystem.cc
+++ b/src/iocore/eventsystem/EventSystem.cc
@@ -50,6 +50,7 @@ ink_event_system_init(ts::ModuleVersion v)
// If we can't parse the string then we can't be sure of the chunk sizes
so just exit
Fatal("Failed to parse proxy.config.allocator.iobuf_chunk_sizes");
}
+ ats_free(chunk_sizes_string);
bool use_hugepages = ats_hugepage_enabled();