mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3: Fix GH-17408: Assertion failure Zend/zend_exceptions.c
This commit is contained in:
2
NEWS
2
NEWS
@@ -16,6 +16,8 @@ PHP NEWS
|
||||
. Fixed NULL arithmetic during system program execution on Windows. (cmb,
|
||||
nielsdos)
|
||||
. Fixed potential OOB when checking for trailing spaces on Windows. (cmb)
|
||||
. Fixed bug GH-17408 (Assertion failure Zend/zend_exceptions.c).
|
||||
(nielsdos, ilutov)
|
||||
|
||||
- DOM:
|
||||
. Fixed bug GH-17397 (Assertion failure ext/dom/php_dom.c). (nielsdos)
|
||||
|
||||
@@ -194,7 +194,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;
|
||||
}
|
||||
}
|
||||
|
||||
22
ext/zend_test/tests/gh17408.phpt
Normal file
22
ext/zend_test/tests/gh17408.phpt
Normal file
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
GH-17408 (Assertion failure Zend/zend_exceptions.c)
|
||||
--EXTENSIONS--
|
||||
zend_test
|
||||
--FILE--
|
||||
<?php
|
||||
function test() {
|
||||
$resource = zend_test_create_throwing_resource();
|
||||
zend_test_create_throwing_resource();
|
||||
}
|
||||
test();
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Uncaught Exception: Throwing resource destructor called in %s:%d
|
||||
Stack trace:
|
||||
#0 %s(%d): test()
|
||||
#1 {main}
|
||||
|
||||
Next Exception: Throwing resource destructor called in %s:%d
|
||||
Stack trace:
|
||||
#0 {main}
|
||||
thrown in %s on line %d
|
||||
Reference in New Issue
Block a user