Skip to contentSkip to conversation

http.c: free preq when aborting

PATCH In review Tay Ray Chuan 1 participant 1 message Jun 15, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/3 http.c: free preq when aborting

Free preq in new_http_pack_request when aborting. preq was allocated before jumping to the 'abort' label so this is safe.

---
 http.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
http.c +1 -0
index a2720d5..cfe32f5 100644
@@ -1059,6 +1059,7 @@ struct http_pack_request *new_http_pack_request(
 
 abort:
 	free(filename);
+	free(preq);
 	return NULL;
 }
 

--
1.6.3.1