From 23ca15aacb7e9a6be3858c48664115141d17ef86 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ale=C5=A1=20Mat=C4=9Bj?= Date: Fri, 19 Jul 2024 09:58:05 +0200 Subject: [PATCH] Free leaking `zck_src` if `zck_init_read` fails --- librepo/downloader.c | 1 + 1 file changed, 1 insertion(+) diff --git a/librepo/downloader.c b/librepo/downloader.c index 40dbeb26..1d696539 100644 --- a/librepo/downloader.c +++ b/librepo/downloader.c @@ -1228,6 +1228,7 @@ find_local_zck_chunks(LrTarget *target, GError **err) zckCtx *zck_src = zck_create(); if(!zck_init_read(zck_src, chk_fd)) { + zck_free(&zck_src); close(chk_fd); continue; }