]> granicus.if.org Git - php/commitdiff
fix bug #38813 (DOMEntityReference->__construct crashes when called explicitly)
authorRob Richards <rrichards@php.net>
Thu, 14 Sep 2006 13:35:02 +0000 (13:35 +0000)
committerRob Richards <rrichards@php.net>
Thu, 14 Sep 2006 13:35:02 +0000 (13:35 +0000)
ext/dom/entityreference.c

index 53ec62548ac1d88e99ed5cd059cc124aa4db821d..4b2686d38238de285eee794624559386140141d7 100644 (file)
@@ -73,7 +73,7 @@ PHP_METHOD(domentityreference, __construct)
 
        intern = (dom_object *)zend_object_store_get_object(id TSRMLS_CC);
        if (intern != NULL) {
-               oldnode = (xmlNodePtr)intern->ptr;
+               oldnode = dom_object_get_node(intern);
                if (oldnode != NULL) {
                        php_libxml_node_free_resource(oldnode  TSRMLS_CC);
                }