From 896cd69dde04832f6b551f681b92bd4557092427 Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Fri, 9 Oct 2015 13:15:44 +0200 Subject: ui-tree: fix resource leak: free before return Coverity-id: 13938 Signed-off-by: Christian Hesse --- ui-tree.c | 1 + 1 file changed, 1 insertion(+) (limited to 'ui-tree.c') diff --git a/ui-tree.c b/ui-tree.c index 1b310d5..d71503d 100644 --- a/ui-tree.c +++ b/ui-tree.c @@ -143,6 +143,7 @@ static int ls_item(const unsigned char *sha1, struct strbuf *base, htmlf("Bad object: %s %s", name, sha1_to_hex(sha1)); + free(name); return 0; } } -- cgit v1.2.3-54-g00ecf