From b16ba2f38b0366d4ec15a973dfd4efad042c9bfa Mon Sep 17 00:00:00 2001 From: zhouzhongyuan Date: Tue, 9 Jul 2019 15:11:01 +0800 Subject: [PATCH] fix memory leak in xmlAllocOutputBuffer --- xmlIO.c | 1 + 1 file changed, 1 insertion(+) mode change 100644 => 100755 xmlIO.c diff --git a/xmlIO.c b/xmlIO.c old mode 100644 new mode 100755 index 299b6d21..ac25d025 --- a/xmlIO.c +++ b/xmlIO.c @@ -2383,6 +2383,7 @@ xmlAllocOutputBuffer(xmlCharEncodingHandlerPtr encoder) { if (encoder != NULL) { ret->conv = xmlBufCreateSize(4000); if (ret->conv == NULL) { + xmlBufFree(ret->buffer); xmlFree(ret); return(NULL); } -- GitLab