summaryrefslogtreecommitdiff
path: root/parser.c
diff options
context:
space:
mode:
authorAlexander Pastukhov <pastuchov@yandex.ru>2013-04-23 13:02:11 +0800
committerDaniel Veillard <veillard@redhat.com>2013-04-23 13:02:11 +0800
commit704d8c5e9ae911715d575abca03900591d56c040 (patch)
tree7aca7ce0317092dcb96be1a2dd3ba0a3cd8e7a27 /parser.c
parentf4e5a6994ed230dfa3fb5b5c3fd94c4993ef1ba7 (diff)
downloadlibxml2-704d8c5e9ae911715d575abca03900591d56c040.tar.gz
Fix an error in xmlCleanupParser
https://bugzilla.gnome.org/show_bug.cgi?id=698582 xmlCleanupParser calls xmlCleanupGlobals() and then xmlResetLastError() but the later reallocate the global data freed by previous call. Just swap the two calls.
Diffstat (limited to 'parser.c')
-rw-r--r--parser.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/parser.c b/parser.c
index ee429f33..b9df6d83 100644
--- a/parser.c
+++ b/parser.c
@@ -14763,8 +14763,8 @@ xmlCleanupParser(void) {
xmlSchemaCleanupTypes();
xmlRelaxNGCleanupTypes();
#endif
- xmlCleanupGlobals();
xmlResetLastError();
+ xmlCleanupGlobals();
xmlCleanupThreads(); /* must be last if called not from the main thread */
xmlCleanupMemory();
xmlParserInitialized = 0;