From: Phil Sutter Date: Wed, 22 Feb 2023 16:30:20 +0000 (+0100) Subject: xlate: Fix for fd leak in error path X-Git-Tag: v7.18~16 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=37f187b1b89a9f40688d9f3b209d6f4df5167c43;p=thirdparty%2Fipset.git xlate: Fix for fd leak in error path A rather cosmetic issue though, the program will terminate anyway. Fixes: 325af556cd3a6 ("add ipset to nftables translation infrastructure") Signed-off-by: Phil Sutter --- diff --git a/lib/ipset.c b/lib/ipset.c index f57b0741..2e098e43 100644 --- a/lib/ipset.c +++ b/lib/ipset.c @@ -1999,7 +1999,7 @@ static int ipset_xlate_restore(struct ipset *ipset) ret = build_argv(ipset, c); if (ret < 0) - return ret; + break; cmd = ipset_parser(ipset, ipset->newargc, ipset->newargv); if (cmd < 0)