[php-src] master: CI: fix ext/zend_test/tests/zend_mm_custom_handlers_alloc_01.phpt (#23775)

From: Date: Sat, 19 Sep 2026 18:12:49 +0000
Subject: [php-src] master: CI: fix ext/zend_test/tests/zend_mm_custom_handlers_alloc_01.phpt (#23775)
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-141287@lists.php.net to get a copy of this message
Author: Weilin Du (LamentXU123) Committer: GitHub (web-flow) Pusher: LamentXU123 Date: 2026-09-20T02:12:46+08:00 Commit: https://github.com/php/php-src/commit/9e75056488d9d90bdb2a9ef053a8a1f6934e8dcd Raw diff: https://github.com/php/php-src/commit/9e75056488d9d90bdb2a9ef053a8a1f6934e8dcd.diff CI: fix ext/zend_test/tests/zend_mm_custom_handlers_alloc_01.phpt (#23775) After 93fd714, we just return the copy of the string when the mult parameter of str_repeat is 1, that is to repeat the string 1 time. But this cause inconsistency in this test. When the rand number is 1, it won't allocate any byte. So the test will fail. Changed paths: M ext/zend_test/tests/zend_mm_custom_handlers_alloc_01.phpt M ext/zend_test/tests/zend_mm_custom_handlers_free_01.phpt Diff: diff --git a/ext/zend_test/tests/zend_mm_custom_handlers_alloc_01.phpt b/ext/zend_test/tests/zend_mm_custom_handlers_alloc_01.phpt index cb6490d4c5d3..b305e260e3fc 100644 --- a/ext/zend_test/tests/zend_mm_custom_handlers_alloc_01.phpt +++ b/ext/zend_test/tests/zend_mm_custom_handlers_alloc_01.phpt @@ -5,7 +5,7 @@ zend_test --FILE-- <?php ini_set('zend_test.zend_mm_custom_handlers.enabled', 1); -$string = str_repeat('String', rand(1,100)); +$string = str_repeat('String', rand(2,100)); ini_set('zend_test.zend_mm_custom_handlers.enabled', 0); ?> --EXPECTREGEX-- diff --git a/ext/zend_test/tests/zend_mm_custom_handlers_free_01.phpt b/ext/zend_test/tests/zend_mm_custom_handlers_free_01.phpt index ae9dacb99950..497cd7aee216 100644 --- a/ext/zend_test/tests/zend_mm_custom_handlers_free_01.phpt +++ b/ext/zend_test/tests/zend_mm_custom_handlers_free_01.phpt @@ -4,7 +4,7 @@ ZendMM Custom Handlers: garbage collection zend_test --FILE-- <?php -$string = str_repeat('String', rand(1,100)); +$string = str_repeat('String', rand(2,100)); ini_set('zend_test.zend_mm_custom_handlers.enabled', 1); unset($string); ini_set('zend_test.zend_mm_custom_handlers.enabled', 0);

« previous php.cvs (#141287) next »