summaryrefslogtreecommitdiff
path: root/xmlsave.c
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>2004-04-29 17:14:25 +0000
committerDaniel Veillard <veillard@src.gnome.org>2004-04-29 17:14:25 +0000
commite2161a699bbd1b58fa90eb43fc94637cbbc29bc8 (patch)
tree64c8122a9b5c9bfb8c4be43c167ea6418125a5e4 /xmlsave.c
parent9ea6231ecef04c848b688355b8f7532dd5e4c6f8 (diff)
downloadlibxml2-e2161a699bbd1b58fa90eb43fc94637cbbc29bc8.tar.gz
fix a nasty problem with reading over the end fix a reported memory leak
* xmlreader.c: fix a nasty problem with reading over the end * xmlsave.c: fix a reported memory leak apparently Daniel
Diffstat (limited to 'xmlsave.c')
-rw-r--r--xmlsave.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/xmlsave.c b/xmlsave.c
index 1a60a315..6e314164 100644
--- a/xmlsave.c
+++ b/xmlsave.c
@@ -179,6 +179,8 @@ xmlFreeSaveCtxt(xmlSaveCtxtPtr ctxt)
if (ctxt == NULL) return;
if (ctxt->encoding != NULL)
xmlFree((char *) ctxt->encoding);
+ if (ctxt->buf != NULL)
+ xmlOutputBufferClose(ctxt->buf);
xmlFree(ctxt);
}