Thread (3 messages) 3 messages, 2 authors, 2021-11-04

[dpdk-dev] [PATCH] test/cmdline: fix memory leak

From: David Marchand <hidden>
Date: 2021-10-29 11:23:50
Subsystem: the rest · Maintainer: Linus Torvalds

Previous change wrongly removed a valid cmdline_free().

Fixes: 6ad06203a587 ("cmdline: free on exit")

Signed-off-by: David Marchand <redacted>
---
 app/test/test_cmdline_lib.c | 2 ++
 1 file changed, 2 insertions(+)
diff --git a/app/test/test_cmdline_lib.c b/app/test/test_cmdline_lib.c
index f238094b07..f50ccdb599 100644
--- a/app/test/test_cmdline_lib.c
+++ b/app/test/test_cmdline_lib.c
@@ -176,6 +176,8 @@ test_cmdline_socket_fns(void)
 		printf("Error: failed to open /dev/null for reading!");
 		return -1;
 	}
+	cmdline_free(cl);
+	cl = NULL;
 
 	/* void functions */
 	cmdline_stdin_exit(NULL);
-- 
2.23.0
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help