From: Dmitry Stogov Date: Fri, 21 Mar 2014 20:00:20 +0000 (+0400) Subject: Fixed refcounting X-Git-Tag: POST_PHPNG_MERGE~412^2~238 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6da4759769d198b4c639ebc4a15ce8cc11472e92;p=php Fixed refcounting --- diff --git a/ext/spl/spl_iterators.c b/ext/spl/spl_iterators.c index f424491966..0857fd5c9f 100644 --- a/ext/spl/spl_iterators.c +++ b/ext/spl/spl_iterators.c @@ -332,7 +332,7 @@ next_step: } object->iterators = erealloc(object->iterators, sizeof(spl_sub_iterator) * (++object->level+1)); sub_iter = ce->get_iterator(ce, &child, 0 TSRMLS_CC); - ZVAL_COPY(&object->iterators[object->level].zobject, &child); + ZVAL_COPY_VALUE(&object->iterators[object->level].zobject, &child); object->iterators[object->level].iterator = sub_iter; object->iterators[object->level].ce = ce; object->iterators[object->level].state = RS_START;