File tree 2 files changed +10
-0
lines changed
2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -53,6 +53,10 @@ PHP NEWS
53
53
- Treewide:
54
54
. Fixed bug GH-17736 (Assertion failure zend_reference_destroy()). (nielsdos)
55
55
56
+ - Windows:
57
+ . Fixed bug GH-17836 (zend_vm_gen.php shouldn't break on Windows line
58
+ endings). (DanielEScherzer)
59
+
56
60
13 Mar 2025, PHP 8.3.19
57
61
58
62
- BCMath:
Original file line number Diff line number Diff line change @@ -2401,6 +2401,12 @@ function gen_vm($def, $skel) {
2401
2401
$ max_opcode = 0 ;
2402
2402
$ extra_num = 256 ;
2403
2403
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
+ }
2404
2410
++$ lineno ;
2405
2411
if (strpos ($ line ,"ZEND_VM_HANDLER( " ) === 0 ||
2406
2412
strpos ($ line ,"ZEND_VM_INLINE_HANDLER( " ) === 0 ||
You can’t perform that action at this time.
0 commit comments