|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2021-03-17 10:06 UTC] nikic@php.net
-Status: Open
+Status: Verified
-Assigned To:
+Assigned To: dmitry
[2021-03-17 10:06 UTC] nikic@php.net
[2021-03-17 13:55 UTC] dmitry@php.net
[2021-03-17 13:55 UTC] dmitry@php.net
-Status: Verified
+Status: Closed
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Nov 01 08:00:02 2025 UTC |
Description: ------------ Running this program results in invalid data. May also causes PHP to crash. Works fine without JIT. The problem has been narrowed as best as I can. The original problem was a PHP crash using JIT in a much larger application. Fails the same in Apache 2.4 or CLI (both 64bits) Test script: --------------- <?php $a = null; // the problem only occurs when set to NULL test($a, 'y'); function test($str, $pad) { $x = $str . str_repeat($pad, 15); // $x now contains "yyyyyyyyyyyyyyy" var_dump($x); echo '<br/>'; $gft = new gft(); $gft->info(33); // $x has been changed ???? // $x contains what was echoed in the function 'info' var_dump($x); echo '<br/>'; } class gft{ private $strVal = 'abcd '; public function info($info, $prefix = ' Info:'){ echo $this->strVal.$prefix.serialize($info).'aaaa'; echo '<br/>'; } } Expected result: ---------------- string(15) "yyyyyyyyyyyyyyy" xxxx Info:i:33;aaaa string(15) "yyyyyyyyyyyyyyy" Actual result: -------------- string(15) "yyyyyyyyyyyyyyy" xxxx Info:i:33;aaaa string(19) "xxxx Info:i:33;aaaa"