fixing leak in xmlTextReaderReadString() #316924 daniel
* xmlreader.c: fixing leak in xmlTextReaderReadString() #316924
daniel
diff --git a/ChangeLog b/ChangeLog
index 10cac20..eaa8cfd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Thu Sep 22 13:14:07 CEST 2005 Daniel Veillard <daniel@veillard.com>
+
+ * xmlreader.c: fixing leak in xmlTextReaderReadString() #316924
+
Thu Sep 15 16:12:44 CEST 2005 Daniel Veillard <daniel@veillard.com>
* uri.c: more fixes to the behaviour of xmlBuildRelativeURI
diff --git a/xmlreader.c b/xmlreader.c
index 7efa273..a74c7a6 100644
--- a/xmlreader.c
+++ b/xmlreader.c
@@ -1200,8 +1200,14 @@
case XML_CDATA_SECTION_NODE:
xmlBufferCat(buffer, node->content);
break;
- case XML_ELEMENT_NODE:
- xmlBufferCat(buffer, xmlTextReaderCollectSiblings(node->children));
+ case XML_ELEMENT_NODE: {
+ xmlChar *tmp;
+
+ tmp = xmlTextReaderCollectSiblings(node->children);
+ xmlBufferCat(buffer, tmp);
+ xmlFree(tmp);
+ break;
+ }
default:
break;
}