File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -53,6 +53,10 @@ PHP NEWS
5353- Treewide:
5454 . Fixed bug GH-17736 (Assertion failure zend_reference_destroy()). (nielsdos)
5555
56+ - Windows:
57+ . Fixed bug GH-17836 (zend_vm_gen.php shouldn't break on Windows line
58+ endings). (DanielEScherzer)
59+
566013 Mar 2025, PHP 8.3.19
5761
5862- BCMath:
Original file line number Diff line number Diff line change @@ -2401,6 +2401,12 @@ function gen_vm($def, $skel) {
24012401 $ max_opcode = 0 ;
24022402 $ extra_num = 256 ;
24032403 foreach ($ in as $ line ) {
2404+ // Handle Windows line endings, GH-17836; since a bunch of regular
2405+ // expressions below test for a newline at the end, just update the
2406+ // ending
2407+ if (substr ($ line , -2 ) === "\r\n" ) {
2408+ $ line = substr_replace ($ line , "\n" , -2 );
2409+ }
24042410 ++$ lineno ;
24052411 if (strpos ($ line ,"ZEND_VM_HANDLER( " ) === 0 ||
24062412 strpos ($ line ,"ZEND_VM_INLINE_HANDLER( " ) === 0 ||
You can’t perform that action at this time.
0 commit comments