com php-src: Fixed use after free on closure_call_leak_wi th_exception.phpt: Zend/zend_execute.c
| From: | Xinchen Hui | Date: | Tue, 07 Jul 2015 10:19:57 +0000 |
| Subject: | com php-src: Fixed use after free on closure_call_leak_wi th_exception.phpt: Zend/zend_execute.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-87778@lists.php.net to get a copy of this message | ||
Commit: 333528089e053b1db35a073955b3ec7244881667
Author: Xinchen Hui <laruence@php.net> Tue, 7 Jul 2015 18:19:57 +0800
Parents: 636c16b186a66c489aaa24b087e288772c297440
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=333528089e053b1db35a073955b3ec7244881667
Log:
Fixed use after free on closure_call_leak_with_exception.phpt
Changed paths:
M Zend/zend_execute.c
Diff:
diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c
index 6122566..3bd1917 100644
--- a/Zend/zend_execute.c
+++ b/Zend/zend_execute.c
@@ -2488,8 +2488,7 @@ static zend_always_inline void
i_cleanup_unfinished_execution(zend_execute_data
}
if (call->func->common.fn_flags & ZEND_ACC_CLOSURE) {
zend_object_release((zend_object *) call->func->common.prototype);
- }
- if (call->func->common.fn_flags & ZEND_ACC_CALL_VIA_TRAMPOLINE) {
+ } else if (call->func->common.fn_flags & ZEND_ACC_CALL_VIA_TRAMPOLINE) {
zend_string_release(call->func->common.function_name);
zend_free_trampoline(call->func);
}