com php-src: Fix build: Zend/zend_generators.c

From: Date: Thu, 17 Mar 2016 02:41:36 +0000
Subject: com php-src: Fix build: Zend/zend_generators.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-91368@lists.php.net to get a copy of this message
Commit: 9583cb84a2d6a3edcfdc6883f868601a5368c6fa Author: Kalle Sommer Nielsen <kalle@php.net> Thu, 17 Mar 2016 03:41:36 +0100 Parents: c808e44d853f42fc277e450971741b8fadaffa8b Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=9583cb84a2d6a3edcfdc6883f868601a5368c6fa Log: Fix build Changed paths: M Zend/zend_generators.c Diff: diff --git a/Zend/zend_generators..c b/Zend/zend_generators.c index 9633fc4..5a3e84c 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -386,6 +386,8 @@ ZEND_API zend_execute_data *zend_generator_check_placeholder_frame(zend_execute_ static void zend_generator_throw_exception(zend_generator *generator, zval *exception) { + zend_execute_data *original_execute_data = EG(current_execute_data); + /* if we don't stop an array/iterator yield from, the exception will only reach the generator after the values were all iterated over */ if (UNEXPECTED(Z_TYPE(generator->values) != IS_UNDEF)) { zval_ptr_dtor(&generator->values); @@ -394,7 +396,6 @@ static void zend_generator_throw_exception(zend_generator *generator, zval *exce /* Throw the exception in the context of the generator.. Decrementing the opline * to pretend the exception happened during the YIELD opcode. */ - zend_execute_data *original_execute_data = EG(current_execute_data); EG(current_execute_data) = generator->execute_data; generator->execute_data->opline--; if (exception) {

« previous php.cvs (#91368) next »