From 1f227f203660c4b216d04f88a23ca2c8c5739281 Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Thu, 18 Apr 2013 16:22:57 +0200 Subject: [PATCH] selection_filter(): Don't leak Queue q1 and Map m2 --- src/selection.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/selection.c b/src/selection.c index 8ec633fc..d179b57e 100644 --- a/src/selection.c +++ b/src/selection.c @@ -803,7 +803,11 @@ selection_filter(Pool *pool, Queue *sel1, Queue *sel2) { Id select = sel2->elements[i] & SOLVER_SELECTMASK; if (select == SOLVER_SOLVABLE_ALL) - return; + { + queue_free(&q1); + map_free(&m2); + return; + } if (select == SOLVER_SOLVABLE_REPO) { Solvable *s; @@ -878,6 +882,8 @@ selection_filter(Pool *pool, Queue *sel1, Queue *sel2) j += 2; } queue_truncate(sel1, j); + queue_free(&q1); + map_free(&m2); } void -- 2.47.2