From: Rob Richards Date: Wed, 23 Nov 2005 02:54:10 +0000 (+0000) Subject: move document property struct from xml_common.h X-Git-Tag: RELEASE_2_0_2~123 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=fba57a97ca6a925a36ffebfe2fa1a123c52d3b96;p=php move document property struct from xml_common.h --- diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index adb48bd7a5..0ac351d997 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -952,6 +952,10 @@ int php_libxml_decrement_doc_ref(php_libxml_node_object *object TSRMLS_DC) { xmlFreeDoc((xmlDoc *) object->document->ptr); } if (object->document->doc_props != NULL) { + if (object->document->doc_props->classmap) { + zend_hash_destroy(object->document->doc_props->classmap); + FREE_HASHTABLE(object->document->doc_props->classmap); + } efree(object->document->doc_props); } efree(object->document); diff --git a/ext/libxml/php_libxml.h b/ext/libxml/php_libxml.h index 584465fd37..ffefff362e 100644 --- a/ext/libxml/php_libxml.h +++ b/ext/libxml/php_libxml.h @@ -43,10 +43,21 @@ typedef struct { zend_llist *error_list; } php_libxml_globals; +typedef struct _libxml_doc_props { + int formatoutput; + int validateonparse; + int resolveexternals; + int preservewhitespace; + int substituteentities; + int stricterror; + int recover; + HashTable *classmap; +} libxml_doc_props; + typedef struct _php_libxml_ref_obj { void *ptr; int refcount; - void *doc_props; + libxml_doc_props *doc_props; } php_libxml_ref_obj; typedef struct _php_libxml_node_ptr {