From: Michael Tremer Date: Tue, 5 Oct 2021 13:42:56 +0000 (+0000) Subject: pakfire: Fix SEGV when free is called before pool is initialized X-Git-Tag: 0.9.28~903 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4e27168b33a168582f95d8dfec483cd9001f739e;p=pakfire.git pakfire: Fix SEGV when free is called before pool is initialized Signed-off-by: Michael Tremer --- diff --git a/src/libpakfire/pakfire.c b/src/libpakfire/pakfire.c index 9882d8683..e40a8e8ce 100644 --- a/src/libpakfire/pakfire.c +++ b/src/libpakfire/pakfire.c @@ -1397,6 +1397,8 @@ ERROR: PAKFIRE_EXPORT struct pakfire_repo* pakfire_get_repo(struct pakfire* pakfire, const char* name) { Pool* pool = pakfire_get_solv_pool(pakfire); + if (!pool) + return NULL; Repo* repo; int i;