Calls xml init and xml cleanup to avoid memory leak

Fix #1553
This commit is contained in:
Felipe Zimmerle
2017-10-10 15:03:50 -03:00
parent 30364628a0
commit 41bf7f716b
3 changed files with 12 additions and 0 deletions

View File

@@ -33,6 +33,10 @@ XML::XML(Transaction *transaction)
XML::~XML() {
if (m_data.parsing_ctx != NULL) {
xmlFreeParserCtxt(m_data.parsing_ctx);
m_data.parsing_ctx = NULL;
}
if (m_data.doc != NULL) {
xmlFreeDoc(m_data.doc);
m_data.doc = NULL;