From d0767ea8eab387c65a90445bfd5d8e6e196c30d6 Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Sun, 6 Feb 2022 14:24:54 +0100 Subject: libq/tree: ensure we free cache.store (for Packages file) Signed-off-by: Fabian Groffen --- libq/tree.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libq/tree.c b/libq/tree.c index 114541dc..db0d2d22 100644 --- a/libq/tree.c +++ b/libq/tree.c @@ -1,5 +1,5 @@ /* - * Copyright 2005-2021 Gentoo Foundation + * Copyright 2005-2022 Gentoo Foundation * Distributed under the terms of the GNU General Public License v2 * * Copyright 2005-2008 Ned Ludd - @@ -194,6 +194,8 @@ tree_close(tree_ctx *ctx) xarrayfree_int(t); } + if (ctx->cache.store != NULL) + free(ctx->cache.store); closedir(ctx->dir); /* closedir() above does this for us: */ -- cgit v1.2.3-65-gdbad