summaryrefslogtreecommitdiff
path: root/ext/dom/php_dom.c
diff options
context:
space:
mode:
authorRob Richards <rrichards@php.net>2003-06-14 18:15:50 +0000
committerRob Richards <rrichards@php.net>2003-06-14 18:15:50 +0000
commitd1bfc58aee0944095757e252074558c5809a55e9 (patch)
treec6346a75fef81d953cda608dd6ce6a8b506ac0f2 /ext/dom/php_dom.c
parentc104c0d6767b0d798f1fd3ea2bcefb3143bd8394 (diff)
downloadphp-git-d1bfc58aee0944095757e252074558c5809a55e9.tar.gz
use xmlInitParser instead of xmlInitThreads
reentrant safe as well no need for xml_parser_inited
Diffstat (limited to 'ext/dom/php_dom.c')
-rw-r--r--ext/dom/php_dom.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/ext/dom/php_dom.c b/ext/dom/php_dom.c
index e3ff995804..08d8f233a4 100644
--- a/ext/dom/php_dom.c
+++ b/ext/dom/php_dom.c
@@ -37,8 +37,6 @@
#define PHP_XPATH 1
#define PHP_XPTR 2
-DOM_IMPORT int xml_parser_inited;
-
zend_object_handlers dom_object_handlers;
static HashTable classes;
@@ -580,10 +578,7 @@ PHP_MINIT_FUNCTION(dom)
REGISTER_LONG_CONSTANT("XML_ATTRIBUTE_ENUMERATION", XML_ATTRIBUTE_ENUMERATION, CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("XML_ATTRIBUTE_NOTATION", XML_ATTRIBUTE_NOTATION, CONST_CS | CONST_PERSISTENT);
- if (!xml_parser_inited) {
- xmlInitThreads();
- xml_parser_inited = 1;
- }
+ xmlInitParser();
return SUCCESS;
}
@@ -611,10 +606,7 @@ PHP_MINFO_FUNCTION(dom)
PHP_MSHUTDOWN_FUNCTION(dom)
{
- if (xml_parser_inited) {
- xmlCleanupParser();
- xml_parser_inited = 0;
- }
+ xmlCleanupParser();
zend_hash_destroy(&dom_domstringlist_prop_handlers);
zend_hash_destroy(&dom_namelist_prop_handlers);