Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ext/dom/dom_iterators.c
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ static void php_dom_iterator_move_forward(zend_object_iterator *iter) /* {{{ */
if (objmap->nodetype != XML_ENTITY_NODE &&
objmap->nodetype != XML_NOTATION_NODE) {
if (objmap->nodetype == DOM_NODESET) {
HashTable *nodeht = HASH_OF(&objmap->baseobj_zv);
HashTable *nodeht = Z_ARRVAL_P(&objmap->baseobj_zv);
zval *entry;
zend_hash_move_forward_ex(nodeht, &iterator->pos);
if ((entry = zend_hash_get_current_data_ex(nodeht, &iterator->pos))) {
Expand Down Expand Up @@ -275,7 +275,7 @@ zend_object_iterator *php_dom_get_iterator(zend_class_entry *ce, zval *object, i
if (objmap->nodetype != XML_ENTITY_NODE &&
objmap->nodetype != XML_NOTATION_NODE) {
if (objmap->nodetype == DOM_NODESET) {
nodeht = HASH_OF(&objmap->baseobj_zv);
nodeht = Z_ARRVAL_P(&objmap->baseobj_zv);
zend_hash_internal_pointer_reset_ex(nodeht, &iterator->pos);
if ((entry = zend_hash_get_current_data_ex(nodeht, &iterator->pos))) {
ZVAL_COPY(&iterator->curobj, entry);
Expand Down
4 changes: 2 additions & 2 deletions ext/dom/nodelist.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ zend_long php_dom_get_nodelist_length(dom_object *obj)
}

if (objmap->nodetype == DOM_NODESET) {
HashTable *nodeht = HASH_OF(&objmap->baseobj_zv);
HashTable *nodeht = Z_ARRVAL_P(&objmap->baseobj_zv);
return zend_hash_num_elements(nodeht);
}

Expand Down Expand Up @@ -145,7 +145,7 @@ void php_dom_nodelist_get_item_into_zval(dom_nnodemap_object *objmap, zend_long
itemnode = php_dom_libxml_hash_iter(objmap, index);
} else {
if (objmap->nodetype == DOM_NODESET) {
HashTable *nodeht = HASH_OF(&objmap->baseobj_zv);
HashTable *nodeht = Z_ARRVAL_P(&objmap->baseobj_zv);
zval *entry = zend_hash_index_find(nodeht, index);
if (entry) {
ZVAL_COPY(return_value, entry);
Expand Down
Loading