projects
/
php
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5829458
)
Fix leak if throw_exception_object() fails
author
Nikita Popov
<nikic@php.net>
Wed, 13 Jul 2016 21:35:53 +0000
(23:35 +0200)
committer
Nikita Popov
<nikic@php.net>
Thu, 14 Jul 2016 16:37:21 +0000
(18:37 +0200)
Zend/zend_exceptions.c
patch
|
blob
|
history
diff --git
a/Zend/zend_exceptions.c
b/Zend/zend_exceptions.c
index 374f3045b3e86fbdef0ea6a1db3a51d2ff54187c..4d1b016cbb3905b21de2970c12fef817bfb1b7e1 100644
(file)
--- a/
Zend/zend_exceptions.c
+++ b/
Zend/zend_exceptions.c
@@
-1070,6
+1070,7
@@
ZEND_API ZEND_COLD void zend_throw_exception_object(zval *exception) /* {{{ */
if (!exception_ce || !instanceof_function(exception_ce, zend_ce_throwable)) {
zend_throw_error(NULL, "Cannot throw objects that do not implement Throwable");
+ zval_ptr_dtor(exception);
return;
}
zend_throw_exception_internal(exception);