Skip to contentSkip to conversation

ctrl: Fix fd leak in ctrl_list()

PATCH New Maks Mishin 1 participant 1 message Feb 6, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ctrl: Fix fd leak in ctrl_list()

---
 genl/ctrl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
genl/ctrl.c +1 -1
index aff922a4..bae73a54 100644
@@ -267,7 +267,7 @@ static int ctrl_list(int cmd, int argc, char **argv)
 
 		if (argc != 2) {
 			fprintf(stderr, "Wrong number of params\n");
-			return -1;
+			goto ctrl_done;
 		}
 
 		if (matches(*argv, "name") == 0) {
Signature · 1 line
2.30.2