mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Fix GH-17408: Assertion failure Zend/zend_exceptions.c
`zend_test_create_throwing_resource` sets the exception in the `test` call frame and unwinds to `main`. It then throws for the `resource` variable and verifies that the exception opline is set. However, it wasn't set in `main`, it was set at the `test` call frame and rethrown later. The assertion is too conservative, but the end result is right, so drop the assertion. Closes GH-17533. Co-authored-by: Ilija Tovilo <ilija.tovilo@me.com>
This commit is contained in:
parent
191e16b703
commit
5344bcca97
3 changed files with 24 additions and 1 deletions
|
@ -193,7 +193,6 @@ ZEND_API ZEND_COLD void zend_throw_exception_internal(zend_object *exception) /*
|
|||
zend_exception_set_previous(exception, EG(exception));
|
||||
EG(exception) = exception;
|
||||
if (previous) {
|
||||
ZEND_ASSERT(is_handle_exception_set() && "HANDLE_EXCEPTION not set?");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue