Commit a16ace8ee78 for php.net
commit a16ace8ee784353ea920591d6ba1af3e4c72286b
Merge: 8cf917990c6 c9a6743b599
Author: ndossche <7771979+ndossche@users.noreply.github.com>
Date: Tue Mar 17 08:47:51 2026 +0100
Merge branch 'PHP-8.5'
* PHP-8.5:
Fix GH-21454: Missing write lock validation in SplHeap
diff --cc ext/spl/spl_heap.c
index 85fc5f8bb69,63ec49afe8a..afe3489e898
--- a/ext/spl/spl_heap.c
+++ b/ext/spl/spl_heap.c
@@@ -963,8 -983,14 +963,12 @@@ PHP_METHOD(SplHeap, next
{
spl_heap_object *intern = Z_SPLHEAP_P(ZEND_THIS);
- if (zend_parse_parameters_none() == FAILURE) {
- RETURN_THROWS();
- }
+ ZEND_PARSE_PARAMETERS_NONE();
+ if (UNEXPECTED(spl_heap_consistency_validations(intern, true) != SUCCESS)) {
+ RETURN_THROWS();
+ }
+
spl_ptr_heap_delete_top(intern->heap, NULL, ZEND_THIS);
}
/* }}} */