Skip to content

Commit 7ee7492

Browse files
committed
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2: NEWS for GH-14814 ext/standard/tests: strings/wordwrap_memory_limit_32bit.phpt has two outputs ext/standard/tests: 32bit wordwrap tests aren't just for Windows
2 parents 519c435 + 1006e10 commit 7ee7492

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

NEWS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ PHP NEWS
3838
- Standard:
3939
. Fixed bug GH-14775 (range function overflow with negative step argument).
4040
(David Carlier)
41+
. Fix 32-bit wordwrap test failures. (orlitzky)
4142

4243
- Treewide:
4344
. Fix compatibility with libxml2 2.13.2. (nielsdos)

ext/standard/tests/strings/wordwrap_memory_limit.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
No overflow should occur during the memory_limit check for wordwrap()
33
--SKIPIF--
44
<?php
5-
if (substr(PHP_OS, 0, 3) == 'WIN' && PHP_INT_SIZE == 4) die("skip this test is not for 32bit Windows platforms");
5+
if (PHP_INT_SIZE == 4) die("skip this test is not for 32bit platforms");
66
if (getenv("USE_ZEND_ALLOC") === "0") die("skip Zend MM disabled");
77
?>
88
--INI--

ext/standard/tests/strings/wordwrap_memory_limit_win32.phpt renamed to ext/standard/tests/strings/wordwrap_memory_limit_32bit.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
No overflow should occur during the memory_limit check for wordwrap()
33
--SKIPIF--
44
<?php
5-
if (substr(PHP_OS, 0, 3) != 'WIN' || PHP_INT_SIZE != 4) die("skip this test is for 32bit Windows platforms only");
5+
if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platforms only");
66
if (getenv("USE_ZEND_ALLOC") === "0") die("skip Zend MM disabled");
77
?>
88
--INI--
@@ -16,4 +16,4 @@ wordwrap($str, 1, $str2);
1616

1717
?>
1818
--EXPECTF--
19-
Fatal error: Possible integer overflow in memory allocation (4294901777 + %d) in %s on line %d
19+
Fatal error: %rAllowed memory size of %d bytes exhausted%s\(tried to allocate %d bytes\)|Possible integer overflow in memory allocation \(4294901777 \+ %d\)%r in %s on line %d

0 commit comments

Comments
 (0)