threads / patch / 42167

patchFix memory leak in git_connect with CONNECT_DIAG_URL

Subject: [PATCH] Fix memory leak in git_connect with CONNECT_DIAG_URL

## tl;dr

One message between Apr 28, 2016 and Apr 28, 2016. Diffs are folded; open one to read it.

replies: 0people: 1as markdown or json

Mike Hommey· Apr 28, 2016, 09:19 UTC · lore
Signed-off-by: Mike Hommey <mh@glandium.org>
---
 connect.c | 1 +
 1 file changed, 1 insertion(+)
Show changes to connect.c +1 −0
diff --git a/connect.c b/connect.c
index c53f3f1..dccf673 100644
--- a/connect.c
+++ b/connect.c
@@ -755,6 +755,7 @@ struct child_process *git_connect(int fd[2], const char *url,
 				free(hostandport);
 				free(path);
 				free(conn);
+				strbuf_release(&cmd);
 				return NULL;
 			}
 
-- 
2.8.1.5.g18c8a48

← back to recent threads