27 lines
714 B
Diff
27 lines
714 B
Diff
From f824a4bd4d341d765a0fb6102a03a733faa15cbb Mon Sep 17 00:00:00 2001
|
|
From: Nick Wellnhofer <wellnhofer@aevum.de>
|
|
Date: Mon, 20 May 2019 13:26:08 +0200
|
|
Subject: [PATCH 37/37] Fix memory leak in xmlAllocOutputBufferInternal error
|
|
path
|
|
|
|
Thanks to Anish K Kurian for the report. Closes #60.
|
|
---
|
|
xmlIO.c | 1 +
|
|
1 file changed, 1 insertion(+)
|
|
|
|
diff --git a/xmlIO.c b/xmlIO.c
|
|
index a0b4532..299b6d2 100644
|
|
--- a/xmlIO.c
|
|
+++ b/xmlIO.c
|
|
@@ -2435,6 +2435,7 @@ xmlAllocOutputBufferInternal(xmlCharEncodingHandlerPtr encoder) {
|
|
if (encoder != NULL) {
|
|
ret->conv = xmlBufCreateSize(4000);
|
|
if (ret->conv == NULL) {
|
|
+ xmlBufFree(ret->buffer);
|
|
xmlFree(ret);
|
|
return(NULL);
|
|
}
|
|
--
|
|
1.8.3.1
|
|
|