mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-07-29 11:41:22 +03:00
started messing seriously with per-document dict and element and attribute
* SAX2.c parser.c parserInternals.c xmlreader.c: started messing seriously with per-document dict and element and attribute nodes reuse in the xmlReader. This seems to lead to an interesting speedup of the xmlReader already. Daniel
This commit is contained in:
@ -2383,6 +2383,26 @@ xmlFreeParserCtxt(xmlParserCtxtPtr ctxt)
|
||||
xmlHashFree(ctxt->attsDefault, (xmlHashDeallocator) xmlFree);
|
||||
if (ctxt->attsSpecial != NULL)
|
||||
xmlHashFree(ctxt->attsSpecial, NULL);
|
||||
if (ctxt->freeElems != NULL) {
|
||||
xmlNodePtr cur, next;
|
||||
|
||||
cur = ctxt->freeElems;
|
||||
while (cur != NULL) {
|
||||
next = cur->next;
|
||||
xmlFree(cur);
|
||||
cur = next;
|
||||
}
|
||||
}
|
||||
if (ctxt->freeAttrs != NULL) {
|
||||
xmlAttrPtr cur, next;
|
||||
|
||||
cur = ctxt->freeAttrs;
|
||||
while (cur != NULL) {
|
||||
next = cur->next;
|
||||
xmlFree(cur);
|
||||
cur = next;
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef LIBXML_CATALOG_ENABLED
|
||||
if (ctxt->catalogs != NULL)
|
||||
|
Reference in New Issue
Block a user