From 55526c52a449907e4d34b829b96141afab530b23 Mon Sep 17 00:00:00 2001 From: Zhi Li Date: Mon, 24 Oct 2022 13:46:54 -0400 Subject: bindresvport.c: fix a potential resource leakage Close the FILE *fp of load_blacklist() in another return path to avoid potential resource leakage. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2135405 Signed-off-by: Zhi Li Signed-off-by: Steve Dickson --- src/bindresvport.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/bindresvport.c b/src/bindresvport.c index 5c0ddcf..efeb1cc 100644 --- a/src/bindresvport.c +++ b/src/bindresvport.c @@ -130,6 +130,7 @@ load_blacklist (void) if (list == NULL) { free (buf); + fclose (fp); return; } } -- cgit v1.2.1