diff options
Diffstat (limited to 'ext/simplexml/simplexml.c')
-rw-r--r-- | ext/simplexml/simplexml.c | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index 01eadf98d0..4ff82631e7 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -352,7 +352,7 @@ long_dim: } if (member == &tmp_zv) { - zval_dtor(&tmp_zv); + zval_ptr_dtor_str(&tmp_zv); } if (Z_ISUNDEF_P(rv)) { @@ -383,7 +383,6 @@ static zval *sxe_dimension_read(zval *object, zval *offset, int type, zval *rv) */ static void change_node_zval(xmlNodePtr node, zval *value) { - zval value_copy; xmlChar *buffer; int buffer_len; @@ -408,9 +407,6 @@ static void change_node_zval(xmlNodePtr node, zval *value) xmlNodeSetContentLen(node, buffer, buffer_len); xmlFree(buffer); } - if (value == &value_copy) { - zval_dtor(value); - } break; default: php_error_docref(NULL, E_WARNING, "It is not possible to assign complex types to nodes"); @@ -470,7 +466,7 @@ long_dim: if (!Z_STRLEN_P(member)) { php_error_docref(NULL, E_WARNING, "Cannot write or create unnamed %s", attribs ? "attribute" : "element"); if (member == &tmp_zv) { - zval_dtor(&tmp_zv); + zval_ptr_dtor_str(&tmp_zv); } return FAILURE; } @@ -531,7 +527,7 @@ long_dim: /* break is missing intentionally */ default: if (member == &tmp_zv) { - zval_dtor(&tmp_zv); + zval_ptr_dtor_str(&tmp_zv); } zend_error(E_WARNING, "It is not yet possible to assign complex types to %s", attribs ? "attributes" : "properties"); return FAILURE; @@ -643,7 +639,7 @@ next_iter: } if (member == &tmp_zv) { - zval_dtor(&tmp_zv); + zval_ptr_dtor_str(&tmp_zv); } if (pnewnode) { *pnewnode = newnode; @@ -801,7 +797,7 @@ static int sxe_prop_dim_exists(zval *object, zval *member, int check_empty, zend } if (member == &tmp_zv) { - zval_dtor(&tmp_zv); + zval_ptr_dtor_str(&tmp_zv); } return exists; @@ -926,7 +922,7 @@ next_iter: } if (member == &tmp_zv) { - zval_dtor(&tmp_zv); + zval_ptr_dtor_str(&tmp_zv); } } /* }}} */ |