webengine/osswebengine/WebCore/platform/symbian/Libxml2/Libxml2_parser.c
changeset 5 10e98eab6f85
parent 0 dd21522fd290
--- a/webengine/osswebengine/WebCore/platform/symbian/Libxml2/Libxml2_parser.c	Fri May 08 08:25:06 2009 +0300
+++ b/webengine/osswebengine/WebCore/platform/symbian/Libxml2/Libxml2_parser.c	Fri Jul 03 15:54:40 2009 +0100
@@ -12412,22 +12412,23 @@
 
 void
 xmlCleanupParser(void) {
-    if (!xmlParserInitialized)
-        return;
-
-    xmlCleanupCharEncodingHandlers();
-#ifdef LIBXML_CATALOG_ENABLED
-    xmlCatalogCleanup();
-#endif
-    xmlCleanupInputCallbacks();
-#ifdef LIBXML_OUTPUT_ENABLED
-    xmlCleanupOutputCallbacks();
-#endif
-    xmlCleanupGlobals();
-    xmlResetLastError();
-    xmlCleanupThreads(); /* must be last if called not from the main thread */
-    xmlCleanupMemory();
-    xmlParserInitialized = 0;
+    if (xmlParserInitialized)
+        {
+        xmlCleanupCharEncodingHandlers();
+    #ifdef LIBXML_CATALOG_ENABLED
+        xmlCatalogCleanup();
+    #endif
+        xmlCleanupInputCallbacks();
+    #ifdef LIBXML_OUTPUT_ENABLED
+        xmlCleanupOutputCallbacks();
+    #endif
+        xmlCleanupGlobals();
+        xmlResetLastError();
+        xmlCleanupThreads(); /* must be last if called not from the main thread */
+        xmlCleanupMemory();
+        xmlParserInitialized = 0;
+        }
+    xecleanTLS();
 }
 
 /************************************************************************