From 7c2dc122f91970ea89a8af0053fbc655a9d58517 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Scharfe?= Date: Sun, 20 Nov 2022 12:00:52 +0100 Subject: list-objects-filter: plug combine_filter_data leak MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit filter_combine__init() allocates a struct combine_filter_data object and assigns it to the filter_data member of struct filter_options. Release it in the complementing filter_combine__free(). Reported-by: Ævar Arnfjörð Bjarmason Signed-off-by: René Scharfe Signed-off-by: Junio C Hamano --- list-objects-filter.c | 1 + 1 file changed, 1 insertion(+) (limited to 'list-objects-filter.c') diff --git a/list-objects-filter.c b/list-objects-filter.c index 1c1ee3d1bb..b9543545ca 100644 --- a/list-objects-filter.c +++ b/list-objects-filter.c @@ -709,6 +709,7 @@ static void filter_combine__free(void *filter_data) BUG("expected oidset to be cleared already"); } free(d->sub); + free(d); } static void add_all(struct oidset *dest, struct oidset *src) { -- cgit v1.2.3