From 90af624d5b25156fa5ebc9c011a0fb830e8f1756 Mon Sep 17 00:00:00 2001 From: Philip Withnall Date: Tue, 24 Jan 2023 11:20:35 +0000 Subject: [PATCH] glib.supp: Add suppression for the one-time allocation in g_get_tmp_dir() Signed-off-by: Philip Withnall --- tools/glib.supp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/tools/glib.supp b/tools/glib.supp index 941d64bc9..9ff78cc15 100644 --- a/tools/glib.supp +++ b/tools/glib.supp @@ -843,7 +843,7 @@ # _g_unset_cached_tmp_dir() deliberately leaks the previous cached g_get_tmp_dir() values. # These will not all be reachable on exit. { - g_get_tmp_dir + g_get_tmp_dir_test_init Memcheck:Leak match-leak-kinds:definite,reachable fun:malloc @@ -853,6 +853,16 @@ fun:g_test_init } +# g_get_tmp_dir() caches a one-time allocation +{ + g_get_tmp_dir + Memcheck:Leak + match-leak-kinds:definite,reachable + fun:malloc + ... + fun:g_get_tmp_dir +} + # g_get_system_data_dirs() caches a one-time allocation { g_get_system_data_dirs