From e1ad50654c5e53f63bbf8651c47bb513a5e0c5d3 Mon Sep 17 00:00:00 2001 From: Jakub Guzik Date: Fri, 19 Feb 2021 10:33:52 +0100 Subject: leak fix in rootless_linux.c fcn can_use_shortcut Signed-off-by: Jakub Guzik --- pkg/rootless/rootless_linux.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'pkg/rootless/rootless_linux.c') diff --git a/pkg/rootless/rootless_linux.c b/pkg/rootless/rootless_linux.c index 2e1fddc48..d588d848b 100644 --- a/pkg/rootless/rootless_linux.c +++ b/pkg/rootless/rootless_linux.c @@ -196,7 +196,11 @@ can_use_shortcut () return false; if (strstr (argv[0], "podman") == NULL) - return false; + { + free (argv[0]); + free (argv); + return false; + } for (argc = 0; argv[argc]; argc++) { -- cgit v1.2.3-54-g00ecf