Skip to content

Commit 0a67213

Browse files
committed
Fix miscellaneous test failures/BORKED
The libxml borked warning was unrelated Fix 32-bit builds and soap tests
1 parent f77650a commit 0a67213

File tree

5 files changed

+39
-5
lines changed

5 files changed

+39
-5
lines changed

Zend/tests/binary-32bit.phpt

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,34 @@ var_dump(-0b11111111111111111111111111111111);
7777
var_dump(-0b1111111111111111111111111111111);
7878
var_dump(-0b111111111111111111111111111111);
7979
var_dump(-0b1);
80-
--EXPECT--
80+
--EXPECTF--
81+
Warning: Saw imprecise float binary literal - the last 1 non-zero bits were truncated in %sbinary-32bit.php on line 55
82+
83+
Warning: Saw imprecise float binary literal - the last 2 non-zero bits were truncated in %sbinary-32bit.php on line 56
84+
85+
Warning: Saw imprecise float binary literal - the last 3 non-zero bits were truncated in %sbinary-32bit.php on line 57
86+
87+
Warning: Saw imprecise float binary literal - the last 4 non-zero bits were truncated in %sbinary-32bit.php on line 58
88+
89+
Warning: Saw imprecise float binary literal - the last 5 non-zero bits were truncated in %sbinary-32bit.php on line 59
90+
91+
Warning: Saw imprecise float binary literal - the last 6 non-zero bits were truncated in %sbinary-32bit.php on line 60
92+
93+
Warning: Saw imprecise float binary literal - the last 7 non-zero bits were truncated in %sbinary-32bit.php on line 61
94+
95+
Warning: Saw imprecise float binary literal - the last 8 non-zero bits were truncated in %sbinary-32bit.php on line 62
96+
97+
Warning: Saw imprecise float binary literal - the last 9 non-zero bits were truncated in %sbinary-32bit.php on line 63
98+
99+
Warning: Saw imprecise float binary literal - the last 10 non-zero bits were truncated in %sbinary-32bit.php on line 64
100+
101+
Warning: Saw imprecise float binary literal - the last 11 non-zero bits were truncated in %sbinary-32bit.php on line 65
102+
103+
Warning: Saw imprecise float binary literal - the last 11 non-zero bits were truncated in %sbinary-32bit.php on line 67
104+
105+
Warning: Saw imprecise float binary literal - the last 10 non-zero bits were truncated in %sbinary-32bit.php on line 68
106+
107+
Warning: Saw imprecise float binary literal - the last 9 non-zero bits were truncated in %sbinary-32bit.php on line 69
81108
int(1)
82109
int(3)
83110
int(7)

Zend/tests/hex_overflow_32bit.phpt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,11 @@ foreach ($doubles as $d) {
2222
echo "Done\n";
2323
?>
2424
--EXPECTF--
25+
Warning: Saw imprecise float hex literal - the last 19 non-zero bits were truncated in %shex_overflow_32bit.php on line 5
26+
27+
Warning: Saw imprecise float hex literal - the last 51 non-zero bits were truncated in %shex_overflow_32bit.php on line 6
28+
29+
Warning: Saw imprecise float hex literal - the last 38 non-zero bits were truncated in %shex_overflow_32bit.php on line 7
2530
float(4.0833602971%dE+14)
2631
float(4.7223664828%dE+21)
2732
float(1.3521606402%dE+31)

ext/libxml/tests/bug79191.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Bug #79191 (Error in SoapClient ctor disables DOMDocument::save())
33
--SKIPIF--
44
<?php
55
if (!extension_loaded('soap')) die('skip soap extension not available');
6-
if (!extension_loaded('dom')) die('dom extension not available');
6+
if (!extension_loaded('dom')) die('skip dom extension not available');
77
?>
88
--FILE--
99
<?php

ext/soap/tests/bug70211.phpt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,6 @@ $ob = unserialize("a:3:{i:0;".serialize($sf).'i:1;R:12;i:2;R:10;}');
2222

2323
var_dump($ob[1]);
2424
?>
25-
--EXPECT--
25+
--EXPECTF--
26+
Warning: Saw imprecise float hex literal - the last 10 non-zero bits were truncated in %sbug70211.php on line 3
2627
string(6) "detail"

ext/spl/tests/bug67247.phpt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,11 @@ Bug #67247 (spl_fixedarray_resize integer overflow)
44
<?php
55
$ar = new SplFixedArray(1);
66
echo "size: ".$ar->getSize()."\n";
7-
$ar->setSize((PHP_INT_SIZE==8)?0x2000000000000001:0x40000001);
7+
$ar->setSize((PHP_INT_SIZE==8)?0x2000_0000_0000_0001:0x40000001);
88
echo "size: ".$ar->getSize()."\n";
99
?>
1010
--EXPECTF--
11+
Warning: Saw imprecise float hex literal - the last 9 non-zero bits were truncated in %sbug67247.php on line 4
1112
size: 1
1213

13-
Fatal error: Possible integer overflow in memory allocation (%d * %d + 0) in %s on line %d
14+
Fatal error: Possible integer overflow in memory allocation (1073741825 * 16 + 0) in %sbug67247.php on line 4

0 commit comments

Comments
 (0)