diff options
author | Anatol Belski <ab@php.net> | 2014-12-13 19:43:45 +0100 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2014-12-13 19:43:45 +0100 |
commit | bb66f385d09e7e55390e9f57fcbca08f6b43ff91 (patch) | |
tree | 54defb44e55c1ebc0afa15aa60758d87a4b9ce3b /ext/standard | |
parent | dfb18b1188492efa48ade07029172c5535f65f93 (diff) | |
parent | 0ea0b591d79ae0ee18d33533a5c701330836ff6b (diff) | |
download | php-git-bb66f385d09e7e55390e9f57fcbca08f6b43ff91.tar.gz |
Merge remote-tracking branch 'origin/master' into native-tls
* origin/master: (37 commits)
NEWS
NEWS
Fix bug #68601 buffer read overflow in gd_gif_in.c
Fixed compilation warnings
Removed unnecessary checks
pcntl_signal_dispatch: Speed up by preventing system calls when unnecessary
Merged PR #911.
Removed ZEND_ACC_FINAL_CLASS which is unnecessary. This also fixed some currently defined classes as final which were just not being considered as such before.
Updated NEWS
Updated NEWS
Updated NEWS
Fix bug #68532: convert.base64-encode omits padding bytes
Updated NEWS
Updated NEWS
Updated NEWS
Fixed Bug #65576 (Constructor from trait conflicts with inherited constructor)
Updated NEWS
Updated NEWS
Fix MySQLi tests
Fixed gd test
...
Diffstat (limited to 'ext/standard')
49 files changed, 175 insertions, 89 deletions
diff --git a/ext/standard/tests/array/array_change_key_case_variation2.phpt b/ext/standard/tests/array/array_change_key_case_variation2.phpt index 929ccb1c6a..d1a479f736 100644 --- a/ext/standard/tests/array/array_change_key_case_variation2.phpt +++ b/ext/standard/tests/array/array_change_key_case_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test array_change_key_case() function : usage variations - Pass different data types as $case arg +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : array array_change_key_case(array $input [, int $case]) @@ -285,4 +287,4 @@ array(3) { ["three"]=> int(3) } -Done
\ No newline at end of file +Done diff --git a/ext/standard/tests/array/array_chunk_variation2.phpt b/ext/standard/tests/array/array_chunk_variation2.phpt index 8cfe994404..93d9218296 100644 --- a/ext/standard/tests/array/array_chunk_variation2.phpt +++ b/ext/standard/tests/array/array_chunk_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test array_chunk() function : usage variations - unexpected values for 'size' argument +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : array array_chunk(array $array, int $size [, bool $preserve_keys]) diff --git a/ext/standard/tests/array/array_fill_variation1.phpt b/ext/standard/tests/array/array_fill_variation1.phpt index e2d0b6f58c..f36da7d0e6 100644 --- a/ext/standard/tests/array/array_fill_variation1.phpt +++ b/ext/standard/tests/array/array_fill_variation1.phpt @@ -124,12 +124,9 @@ array(2) { int(100) } -- Iteration 3 -- -array(2) { - [-1097262584]=> - int(100) - [0]=> - int(100) -} + +Warning: array_fill() expects parameter 1 to be long, double given in /Users/ajf/Projects/2014/PHP/php-src/ext/standard/tests/array/array_fill_variation1.php on line 92 +NULL -- Iteration 4 -- array(2) { [0]=> diff --git a/ext/standard/tests/array/array_pad_variation2.phpt b/ext/standard/tests/array/array_pad_variation2.phpt index 0267f203bb..f00c5908d6 100644 --- a/ext/standard/tests/array/array_pad_variation2.phpt +++ b/ext/standard/tests/array/array_pad_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test array_pad() function : usage variations - unexpected values for 'pad_size' argument(Bug#43482) +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : array array_pad(array $input, int $pad_size, mixed $pad_value) diff --git a/ext/standard/tests/array/array_rand_variation2.phpt b/ext/standard/tests/array/array_rand_variation2.phpt index 3340a12b51..fe92181906 100644 --- a/ext/standard/tests/array/array_rand_variation2.phpt +++ b/ext/standard/tests/array/array_rand_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test array_rand() function : usage variations - unexpected values for 'num_req' parameter +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : mixed array_rand(array input [, int num_req]) diff --git a/ext/standard/tests/array/array_slice_variation2.phpt b/ext/standard/tests/array/array_slice_variation2.phpt index 217788fec7..8ec240818c 100644 --- a/ext/standard/tests/array/array_slice_variation2.phpt +++ b/ext/standard/tests/array/array_slice_variation2.phpt @@ -152,16 +152,9 @@ array(4) { } -- Iteration 7 -- -array(4) { - ["one"]=> - int(1) - [0]=> - int(2) - ["three"]=> - int(3) - [1]=> - int(4) -} + +Warning: array_slice() expects parameter 2 to be long, double given in %s on line %d +NULL -- Iteration 8 -- array(4) { diff --git a/ext/standard/tests/array/count_variation2.phpt b/ext/standard/tests/array/count_variation2.phpt index 86aecc07b1..a45bf0cf2c 100644 --- a/ext/standard/tests/array/count_variation2.phpt +++ b/ext/standard/tests/array/count_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test count() function : usage variations - Pass different data types as $mode arg +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : int count(mixed $var [, int $mode]) @@ -184,4 +186,4 @@ int(3) Warning: count() expects parameter 2 to be long, resource given in %s on line %d NULL -Done
\ No newline at end of file +Done diff --git a/ext/standard/tests/array/rsort_variation2.phpt b/ext/standard/tests/array/rsort_variation2.phpt index 2196a6494d..14ca057038 100644 --- a/ext/standard/tests/array/rsort_variation2.phpt +++ b/ext/standard/tests/array/rsort_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test rsort() function : usage variations - Pass different data types as $sort_flags arg +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : bool rsort(array &$array_arg [, int $sort_flags]) @@ -481,4 +483,4 @@ array(5) { [4]=> int(1) } -Done
\ No newline at end of file +Done diff --git a/ext/standard/tests/dir/scandir_variation2.phpt b/ext/standard/tests/dir/scandir_variation2.phpt index e6033f256c..0d8199b39a 100644 --- a/ext/standard/tests/dir/scandir_variation2.phpt +++ b/ext/standard/tests/dir/scandir_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test scandir() function : usage variations - diff data types as $sorting_order arg +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : array scandir(string $dir [, int $sorting_order [, resource $context]]) diff --git a/ext/standard/tests/file/bug68532.phpt b/ext/standard/tests/file/bug68532.phpt new file mode 100644 index 0000000000..7d1a0cea9a --- /dev/null +++ b/ext/standard/tests/file/bug68532.phpt @@ -0,0 +1,25 @@ +--TEST-- +Bug #68532: convert.base64-encode omits padding bytes +--FILE-- +<?php +$testString = 'test'; +$stream = fopen('php://memory','r+'); +fwrite($stream, $testString); +rewind($stream); +$filter = stream_filter_append($stream, 'convert.base64-encode'); +echo "memoryStream = " . stream_get_contents($stream).PHP_EOL; + + +$fileStream = fopen(__DIR__ . '/base64test.txt','w+'); +fwrite($fileStream , $testString); +rewind($fileStream ); +$filter = stream_filter_append($fileStream , 'convert.base64-encode'); +echo "fileStream = " . stream_get_contents($fileStream ).PHP_EOL; +?> +--CLEAN-- +<?php +unlink(__DIR__ . '/base64test.txt'); +?> +--EXPECT-- +memoryStream = dGVzdA== +fileStream = dGVzdA== diff --git a/ext/standard/tests/file/chmod_variation4.phpt b/ext/standard/tests/file/chmod_variation4.phpt index 15310f1ca8..70615755c4 100644 --- a/ext/standard/tests/file/chmod_variation4.phpt +++ b/ext/standard/tests/file/chmod_variation4.phpt @@ -1,5 +1,7 @@ --TEST-- Test chmod() function : second parameter variation +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : bool chmod(string filename, int mode) diff --git a/ext/standard/tests/file/file_get_contents_variation5.phpt b/ext/standard/tests/file/file_get_contents_variation5.phpt index ce88d3c3be..e2dafbe0ee 100644 --- a/ext/standard/tests/file/file_get_contents_variation5.phpt +++ b/ext/standard/tests/file/file_get_contents_variation5.phpt @@ -2,6 +2,8 @@ Test file_get_contents() function : usage variation --CREDITS-- Dave Kelsey <d_kelsey@uk.ibm.com> +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : string file_get_contents(string filename [, bool use_include_path [, resource context [, long offset [, long maxlen]]]]) diff --git a/ext/standard/tests/file/file_variation3.phpt b/ext/standard/tests/file/file_variation3.phpt index 1dd8520a9e..54635d6d86 100644 --- a/ext/standard/tests/file/file_variation3.phpt +++ b/ext/standard/tests/file/file_variation3.phpt @@ -1,5 +1,7 @@ --TEST-- Test file() function : second parameter variation +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : array file(string filename [, int flags[, resource context]]) diff --git a/ext/standard/tests/file/fseek_variation2.phpt b/ext/standard/tests/file/fseek_variation2.phpt index f454352301..5377843716 100644 --- a/ext/standard/tests/file/fseek_variation2.phpt +++ b/ext/standard/tests/file/fseek_variation2.phpt @@ -2,6 +2,8 @@ Test fseek() function : usage variations - different types for whence --CREDITS-- Dave Kelsey <d_kelsey@uk.ibm.com> +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : proto int fseek(resource fp, int offset [, int whence]) diff --git a/ext/standard/tests/file/mkdir_variation2.phpt b/ext/standard/tests/file/mkdir_variation2.phpt index ab9a676ac1..48e6cb8722 100644 --- a/ext/standard/tests/file/mkdir_variation2.phpt +++ b/ext/standard/tests/file/mkdir_variation2.phpt @@ -2,6 +2,8 @@ Test mkdir() function : usage variation: different types for mode --CREDITS-- Dave Kelsey <d_kelsey@uk.ibm.com> +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : bool mkdir(string pathname [, int mode [, bool recursive [, resource context]]]) diff --git a/ext/standard/tests/file/pathinfo_variation2.phpt b/ext/standard/tests/file/pathinfo_variation2.phpt index 9d18a4b79d..897b2d9836 100644 --- a/ext/standard/tests/file/pathinfo_variation2.phpt +++ b/ext/standard/tests/file/pathinfo_variation2.phpt @@ -2,6 +2,8 @@ Test pathinfo() function : usage variation --CREDITS-- Dave Kelsey <d_kelsey@uk.ibm.com> +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : array pathinfo(string path[, int options]) diff --git a/ext/standard/tests/file/stream_rfc2397_007.phpt b/ext/standard/tests/file/stream_rfc2397_007.phpt index 8a6f3155dd..b62f19cd37 100644 --- a/ext/standard/tests/file/stream_rfc2397_007.phpt +++ b/ext/standard/tests/file/stream_rfc2397_007.phpt @@ -27,6 +27,7 @@ foreach($streams as $stream) var_dump(feof($fp)); echo "===GETC===\n"; var_dump(fgetc($fp)); + var_dump(fgetc($fp)); var_dump(ftell($fp)); var_dump(feof($fp)); echo "===REWIND===\n"; @@ -94,6 +95,7 @@ int(5) bool(false) ===GETC=== string(1) "5" +bool(false) int(6) bool(true) ===REWIND=== diff --git a/ext/standard/tests/file/touch_variation3.phpt b/ext/standard/tests/file/touch_variation3.phpt index 810cd71ef6..87cb199f8f 100644 --- a/ext/standard/tests/file/touch_variation3.phpt +++ b/ext/standard/tests/file/touch_variation3.phpt @@ -4,6 +4,7 @@ Test touch() function : usage variation - different types for time Dave Kelsey <d_kelsey@uk.ibm.com> --SKIPIF-- <?php +if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); if (substr(PHP_OS, 0, 3) == 'WIN') { die('skip.. Not for Windows'); } diff --git a/ext/standard/tests/file/touch_variation4.phpt b/ext/standard/tests/file/touch_variation4.phpt index b0238b1759..384b68b384 100644 --- a/ext/standard/tests/file/touch_variation4.phpt +++ b/ext/standard/tests/file/touch_variation4.phpt @@ -4,6 +4,7 @@ Test touch() function : usage variation - different types for atime Dave Kelsey <d_kelsey@uk.ibm.com> --SKIPIF-- <?php +if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); if (substr(PHP_OS, 0, 3) == 'WIN') { die('skip.. Not for Windows'); } diff --git a/ext/standard/tests/file/umask_variation3.phpt b/ext/standard/tests/file/umask_variation3.phpt index c666c328df..7885d0e5b8 100644 --- a/ext/standard/tests/file/umask_variation3.phpt +++ b/ext/standard/tests/file/umask_variation3.phpt @@ -4,6 +4,7 @@ Test umask() function : usage variation Dave Kelsey <d_kelsey@uk.ibm.com> --SKIPIF-- <?php +if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); if (substr(PHP_OS, 0, 3) == 'WIN') { die('skip.. only for Non Windows'); } diff --git a/ext/standard/tests/general_functions/getrusage_variation1.phpt b/ext/standard/tests/general_functions/getrusage_variation1.phpt index 3daf9e5e61..ae2b150548 100644 --- a/ext/standard/tests/general_functions/getrusage_variation1.phpt +++ b/ext/standard/tests/general_functions/getrusage_variation1.phpt @@ -2,6 +2,7 @@ Test getrusage() function : usage variation - diff data types as $who arg --SKIPIF-- <?php +if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); if( substr(PHP_OS, 0, 3) == "WIN" ) die("skip.. Do not run on Windows"); ?> diff --git a/ext/standard/tests/general_functions/intval_variation2.phpt b/ext/standard/tests/general_functions/intval_variation2.phpt index 65bc584254..8fdab26caa 100644 --- a/ext/standard/tests/general_functions/intval_variation2.phpt +++ b/ext/standard/tests/general_functions/intval_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test intval() function : usage variation +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php /* Prototype : int intval(mixed var [, int base]) @@ -113,10 +115,12 @@ int(1) int(1) --float 12.3456789000e10-- -int(1) +Error: 2 - intval() expects parameter 2 to be long, double given, %s(%d) +NULL --float -12.3456789000e10-- -int(1) +Error: 2 - intval() expects parameter 2 to be long, double given, %s(%d) +NULL --float .5-- int(1) @@ -192,4 +196,4 @@ int(1) --unset var-- int(1) -===DONE===
\ No newline at end of file +===DONE=== diff --git a/ext/standard/tests/image/image_type_to_mime_type_variation1.phpt b/ext/standard/tests/image/image_type_to_mime_type_variation1.phpt index 0023b7125d..5b941f7556 100644 --- a/ext/standard/tests/image/image_type_to_mime_type_variation1.phpt +++ b/ext/standard/tests/image/image_type_to_mime_type_variation1.phpt @@ -1,5 +1,7 @@ --TEST-- Test image_type_to_mime_type() function : usage variations - Pass different data types as imagetype +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : string image_type_to_mime_type(int imagetype) @@ -149,4 +151,4 @@ string(24) "application/octet-stream" -- Iteration 20 -- string(24) "application/octet-stream" -===DONE===
\ No newline at end of file +===DONE=== diff --git a/ext/standard/tests/math/mt_rand_variation2.phpt b/ext/standard/tests/math/mt_rand_variation2.phpt index 2174a349e5..817252edd5 100644 --- a/ext/standard/tests/math/mt_rand_variation2.phpt +++ b/ext/standard/tests/math/mt_rand_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test mt_rand() function : usage variations - different data types as $max argument +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php /* Prototype : int mt_rand ([ int $min , int $max ] ) @@ -110,7 +112,9 @@ int(%i) int(%i) -- Iteration 8 -- -int(%i) + +Warning: mt_rand() expects parameter 2 to be long, double given in %s on line %d +NULL -- Iteration 9 -- int(%i) diff --git a/ext/standard/tests/math/mt_srand_variation1.phpt b/ext/standard/tests/math/mt_srand_variation1.phpt index feb0b37972..0344f78252 100644 --- a/ext/standard/tests/math/mt_srand_variation1.phpt +++ b/ext/standard/tests/math/mt_srand_variation1.phpt @@ -1,5 +1,7 @@ --TEST-- Test mt_srand() function : usage variations - different data types as $seed argument +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php /* Prototype : void mt_srand ([ int $seed ] ) @@ -110,6 +112,8 @@ NULL NULL -- Iteration 8 -- + +Warning: mt_srand() expects parameter 1 to be long, double given in %s on line %d NULL -- Iteration 9 -- diff --git a/ext/standard/tests/math/rand_variation1.phpt b/ext/standard/tests/math/rand_variation1.phpt index 02e552b784..b9e7c81621 100644 --- a/ext/standard/tests/math/rand_variation1.phpt +++ b/ext/standard/tests/math/rand_variation1.phpt @@ -1,5 +1,7 @@ --TEST-- Test rand() function : usage variations - different data types as $min argument +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php /* Prototype : int rand ([ int $min , int $max ] ) @@ -110,7 +112,9 @@ int(%i) int(%i) -- Iteration 8 -- -int(%i) + +Warning: rand() expects parameter 1 to be long, double given in %s on line %d +NULL -- Iteration 9 -- int(%i) diff --git a/ext/standard/tests/math/rand_variation2.phpt b/ext/standard/tests/math/rand_variation2.phpt index c0e1fc6373..5ebd274aa6 100644 --- a/ext/standard/tests/math/rand_variation2.phpt +++ b/ext/standard/tests/math/rand_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test rand() function : usage variations - different data types as $max argument +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php /* Prototype : int rand ([ int $min , int $max ] ) @@ -110,7 +112,9 @@ int(%i) int(%i) -- Iteration 8 -- -int(%i) + +Warning: rand() expects parameter 2 to be long, double given in %s on line %d +NULL -- Iteration 9 -- int(%i) diff --git a/ext/standard/tests/math/srand_variation1.phpt b/ext/standard/tests/math/srand_variation1.phpt index 16da80fd6a..cdd98850ae 100644 --- a/ext/standard/tests/math/srand_variation1.phpt +++ b/ext/standard/tests/math/srand_variation1.phpt @@ -1,5 +1,7 @@ --TEST-- Test srand() function : usage variations - different data types as $seed argument +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php /* Prototype : void srand ([ int $seed ] ) @@ -110,6 +112,8 @@ NULL NULL -- Iteration 8 -- + +Warning: srand() expects parameter 1 to be long, double given in %s on line %d NULL -- Iteration 9 -- diff --git a/ext/standard/tests/strings/bug54322.phpt b/ext/standard/tests/strings/bug54322.phpt index aead172b82..4834bdf236 100644 --- a/ext/standard/tests/strings/bug54322.phpt +++ b/ext/standard/tests/strings/bug54322.phpt @@ -5,5 +5,6 @@ Bug #54322: Null pointer deref in get_html_translation_table due to information var_dump( get_html_translation_table(NAN, 0, "UTF-8") > 0 ); ---EXPECT-- -bool(true) +--EXPECTF-- +Warning: get_html_translation_table() expects parameter 1 to be long, double given in %s on line %d +bool(false) diff --git a/ext/standard/tests/strings/chunk_split_variation2.phpt b/ext/standard/tests/strings/chunk_split_variation2.phpt index d49ec3b1bd..1503d520f4 100644 --- a/ext/standard/tests/strings/chunk_split_variation2.phpt +++ b/ext/standard/tests/strings/chunk_split_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test chunk_split() function : usage variations - unexpected values for 'chunklen' argument(Bug#42796) +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : string chunk_split(string $str [, int $chunklen [, string $ending]]) @@ -98,8 +100,8 @@ Warning: chunk_split(): Chunk length should be greater than zero in %schunk_spli bool(false) -- Iteration 3 -- -Warning: chunk_split(): Chunk length should be greater than zero in %schunk_split_variation2.php on line %d -bool(false) +Warning: chunk_split() expects parameter 2 to be long, double given in %s on line %d +NULL -- Iteration 4 -- Warning: chunk_split(): Chunk length should be greater than zero in %schunk_split_variation2.php on line %d diff --git a/ext/standard/tests/strings/chunk_split_variation5.phpt b/ext/standard/tests/strings/chunk_split_variation5.phpt Binary files differindex 580f8f0a6f..ca34959354 100644 --- a/ext/standard/tests/strings/chunk_split_variation5.phpt +++ b/ext/standard/tests/strings/chunk_split_variation5.phpt diff --git a/ext/standard/tests/strings/chunk_split_variation8.phpt b/ext/standard/tests/strings/chunk_split_variation8.phpt index cfb440e923..7f1e4959d4 100644 --- a/ext/standard/tests/strings/chunk_split_variation8.phpt +++ b/ext/standard/tests/strings/chunk_split_variation8.phpt @@ -83,8 +83,8 @@ It has _speci@l ch@r$ 2222 !!!Now \k as escape char to test chunk_split():::" -- Iteration 7 -- -Warning: chunk_split(): Chunk length should be greater than zero in %s on line %d -bool(false) +Warning: chunk_split() expects parameter 2 to be long, double given in %s on line %d +NULL -- Iteration 8 -- Warning: chunk_split(): Chunk length should be greater than zero in %s on line %d diff --git a/ext/standard/tests/strings/count_chars_variation2.phpt b/ext/standard/tests/strings/count_chars_variation2.phpt index 7a17cb9c61..fe9597e3ae 100644 --- a/ext/standard/tests/strings/count_chars_variation2.phpt +++ b/ext/standard/tests/strings/count_chars_variation2.phpt @@ -1,5 +1,7 @@ --TEST-- Test count_chars() function : usage variations - test values for $mode argument +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php diff --git a/ext/standard/tests/strings/explode.phpt b/ext/standard/tests/strings/explode.phpt index 1047fb7856..4c7a3fe45a 100644 --- a/ext/standard/tests/strings/explode.phpt +++ b/ext/standard/tests/strings/explode.phpt @@ -2,6 +2,8 @@ explode() function --INI-- error_reporting=2047 +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* From http://bugs.php.net/19865 */ diff --git a/ext/standard/tests/strings/htmlspecialchars_decode_variation2.phpt b/ext/standard/tests/strings/htmlspecialchars_decode_variation2.phpt index 0e26d094a8..8fc4068b9a 100644 --- a/ext/standard/tests/strings/htmlspecialchars_decode_variation2.phpt +++ b/ext/standard/tests/strings/htmlspecialchars_decode_variation2.phpt @@ -102,7 +102,9 @@ string(104) "<html>Roy's height > Sam's height. 13 < 15. 1111 & 0000 = string(104) "<html>Roy's height > Sam's height. 13 < 15. 1111 & 0000 = 0000. " double quote string "</html>" -- Iteration 3 -- -string(114) "<html>Roy's height > Sam's height. 13 < 15. 1111 & 0000 = 0000. " double quote string "</html>" + +Warning: htmlspecialchars_decode() expects parameter 2 to be long, double given in %s on line %d +NULL -- Iteration 4 -- string(114) "<html>Roy's height > Sam's height. 13 < 15. 1111 & 0000 = 0000. " double quote string "</html>" diff --git a/ext/standard/tests/strings/str_pad_variation4.phpt b/ext/standard/tests/strings/str_pad_variation4.phpt index a622304c82..d2b51af0a3 100644 --- a/ext/standard/tests/strings/str_pad_variation4.phpt +++ b/ext/standard/tests/strings/str_pad_variation4.phpt @@ -1,5 +1,7 @@ --TEST-- Test str_pad() function : usage variations - unexpected inputs for '$pad_type' argument +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : string str_pad ( string $input , int $pad_length [, string $pad_string [, int $pad_type ]] ) diff --git a/ext/standard/tests/strings/str_split_variation2.phpt b/ext/standard/tests/strings/str_split_variation2.phpt index ba1297b405..423d9d894c 100644 --- a/ext/standard/tests/strings/str_split_variation2.phpt +++ b/ext/standard/tests/strings/str_split_variation2.phpt @@ -111,8 +111,8 @@ Warning: str_split(): The length of each segment must be greater than zero in %s bool(false) --Iteration 3 -- -Warning: str_split(): The length of each segment must be greater than zero in %sstr_split_variation2.php on line %d -bool(false) +Warning: str_split() expects parameter 2 to be long, double given in %s on line %d +NULL --Iteration 4 -- Warning: str_split(): The length of each segment must be greater than zero in %sstr_split_variation2.php on line %d diff --git a/ext/standard/tests/strings/str_split_variation6.phpt b/ext/standard/tests/strings/str_split_variation6.phpt index 6d751bbccf..049d1fe401 100644 --- a/ext/standard/tests/strings/str_split_variation6.phpt +++ b/ext/standard/tests/strings/str_split_variation6.phpt @@ -157,8 +157,8 @@ array(1) { } -- Iteration 7 -- -Warning: str_split(): The length of each segment must be greater than zero in %s on line %d -bool(false) +Warning: str_split() expects parameter 2 to be long, double given in %s line %d +NULL -- Iteration 8 -- Warning: str_split(): The length of each segment must be greater than zero in %s on line %d diff --git a/ext/standard/tests/strings/str_split_variation7.phpt b/ext/standard/tests/strings/str_split_variation7.phpt index 455c5b8972..ee0e88c51a 100644 --- a/ext/standard/tests/strings/str_split_variation7.phpt +++ b/ext/standard/tests/strings/str_split_variation7.phpt @@ -135,8 +135,8 @@ array(1) { } -- Iteration 7 -- -Warning: str_split(): The length of each segment must be greater than zero in %s on line %d -bool(false) +Warning: str_split() expects parameter 2 to be long, double given in %s on line %d +NULL -- Iteration 8 -- Warning: str_split(): The length of each segment must be greater than zero in %s on line %d diff --git a/ext/standard/tests/strings/strcspn_variation4.phpt b/ext/standard/tests/strings/strcspn_variation4.phpt index d456a23318..04d9bceae1 100644 --- a/ext/standard/tests/strings/strcspn_variation4.phpt +++ b/ext/standard/tests/strings/strcspn_variation4.phpt @@ -1,5 +1,7 @@ --TEST-- Test strcspn() function : usage variations - unexpected values of len argument +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : proto int strcspn(string str, string mask [, int start [, int len]]) @@ -193,4 +195,4 @@ int(0) Warning: strcspn() expects parameter 4 to be long, resource given in %s on line %d NULL -Done
\ No newline at end of file +Done diff --git a/ext/standard/tests/strings/stripos_variation14.phpt b/ext/standard/tests/strings/stripos_variation14.phpt index 023585dbb7..a6407425dd 100644 --- a/ext/standard/tests/strings/stripos_variation14.phpt +++ b/ext/standard/tests/strings/stripos_variation14.phpt @@ -1,5 +1,7 @@ --TEST-- Test stripos() function : usage variations - unexpected inputs for 'offset' argument +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : int stripos ( string $haystack, string $needle [, int $offset] ); diff --git a/ext/standard/tests/strings/stripos_variation15.phpt b/ext/standard/tests/strings/stripos_variation15.phpt index 2304c1d350..fd01cf8bd0 100644 --- a/ext/standard/tests/strings/stripos_variation15.phpt +++ b/ext/standard/tests/strings/stripos_variation15.phpt @@ -1,5 +1,7 @@ --TEST-- Test stripos() function : usage variations - unexpected inputs for 'haystack', 'needle' & 'offset' arguments +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : int stripos ( string $haystack, string $needle [, int $offset] ); diff --git a/ext/standard/tests/strings/strncasecmp_variation5.phpt b/ext/standard/tests/strings/strncasecmp_variation5.phpt index c391ba3e92..dc17b20043 100644 --- a/ext/standard/tests/strings/strncasecmp_variation5.phpt +++ b/ext/standard/tests/strings/strncasecmp_variation5.phpt @@ -1,5 +1,7 @@ --TEST-- Test strncasecmp() function : usage variations - unexpected values for 'len' +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : int strncasecmp ( string $str1, string $str2, int $len ); diff --git a/ext/standard/tests/strings/strncmp_variation5.phpt b/ext/standard/tests/strings/strncmp_variation5.phpt index 73d7e8f319..36648c8b60 100644 --- a/ext/standard/tests/strings/strncmp_variation5.phpt +++ b/ext/standard/tests/strings/strncmp_variation5.phpt @@ -1,5 +1,7 @@ --TEST-- Test strncmp() function : usage variations - different lengths(all types) +--SKIPIF-- +<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64-bit only"); --FILE-- <?php /* Prototype : int strncmp ( string $str1, string $str2, int $len ); diff --git a/ext/standard/tests/strings/strripos_offset.phpt b/ext/standard/tests/strings/strripos_offset.phpt index 524699ad52..f6124c022d 100644 --- a/ext/standard/tests/strings/strripos_offset.phpt +++ b/ext/standard/tests/strings/strripos_offset.phpt @@ -1,5 +1,7 @@ --TEST-- strripos() offset integer overflow +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php @@ -16,16 +18,16 @@ var_dump(strripos(1024, "te", -PHP_INT_MAX-1)); echo "Done\n"; ?> --EXPECTF-- -Warning: strripos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strripos() expects parameter 3 to be long, double given in %s on line %d bool(false) -Warning: strripos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strripos() expects parameter 3 to be long, double given in %s on line %d bool(false) -Warning: strripos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strripos() expects parameter 3 to be long, double given in %s on line %d bool(false) -Warning: strripos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strripos() expects parameter 3 to be long, double given in %s on line %d bool(false) Warning: strripos() expects parameter 1 to be string, array given in %s on line %d diff --git a/ext/standard/tests/strings/strrpos_offset.phpt b/ext/standard/tests/strings/strrpos_offset.phpt index 18b5847063..41540f1b46 100644 --- a/ext/standard/tests/strings/strrpos_offset.phpt +++ b/ext/standard/tests/strings/strrpos_offset.phpt @@ -1,5 +1,7 @@ --TEST-- strrpos() offset integer overflow +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php @@ -15,16 +17,16 @@ var_dump(strrpos(1024, "te", -PHP_INT_MAX-1)); echo "Done\n"; ?> --EXPECTF-- -Warning: strrpos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strrpos() expects parameter 3 to be long, double given in %s on line %d bool(false) -Warning: strrpos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strrpos() expects parameter 3 to be long, double given in %s on line %d bool(false) -Warning: strrpos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strrpos() expects parameter 3 to be long, double given in %s on line %d bool(false) -Warning: strrpos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strrpos() expects parameter 3 to be long, double given in %s on line %d bool(false) Warning: strrpos(): Offset is greater than the length of haystack string in %s on line %d diff --git a/ext/standard/tests/strings/strrpos_variation14.phpt b/ext/standard/tests/strings/strrpos_variation14.phpt index 53c123a3fd..9b5d2154e8 100644 --- a/ext/standard/tests/strings/strrpos_variation14.phpt +++ b/ext/standard/tests/strings/strrpos_variation14.phpt @@ -1,5 +1,7 @@ --TEST-- Test strrpos() function : usage variations - unexpected inputs for 'offset' argument +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php /* Prototype : int strrpos ( string $haystack, string $needle [, int $offset] ); @@ -92,7 +94,7 @@ int(6) int(6) -- Iteration 3 -- -Warning: strrpos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strrpos() expects parameter 3 to be long, double given in %s on line %d bool(false) -- Iteration 4 -- int(6) diff --git a/ext/standard/tests/strings/strrpos_variation15.phpt b/ext/standard/tests/strings/strrpos_variation15.phpt index d958cdc485..412454913c 100644 --- a/ext/standard/tests/strings/strrpos_variation15.phpt +++ b/ext/standard/tests/strings/strrpos_variation15.phpt @@ -1,5 +1,7 @@ --TEST-- Test strrpos() function : usage variations - unexpected inputs for 'haystack', 'needle' & 'offset' arguments +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) die("skip this test is for 32-bit only"); --FILE-- <?php /* Prototype : int strrpos ( string $haystack, string $needle [, int $offset] ); @@ -110,7 +112,7 @@ Warning: strrpos(): Offset is greater than the length of haystack string in %s o bool(false) -- Iteration 7 -- -Warning: strrpos(): Offset is greater than the length of haystack string in %s on line %d +Warning: strrpos() expects parameter 3 to be long, double given in %s on line %d bool(false) -- Iteration 8 -- bool(false) diff --git a/ext/standard/tests/url/parse_url_variation_002_32bit.phpt b/ext/standard/tests/url/parse_url_variation_002_32bit.phpt index aefb37a117..a0b8615b75 100644 --- a/ext/standard/tests/url/parse_url_variation_002_32bit.phpt +++ b/ext/standard/tests/url/parse_url_variation_002_32bit.phpt @@ -80,11 +80,11 @@ echo "Done"; ?> --EXPECTF-- *** Testing parse_url() : usage variations *** -Error: 8 - Undefined variable: undefined_var, %s(61) -Error: 8 - Undefined variable: unset_var, %s(64) +Error: 8 - Undefined variable: undefined_var, %s(%d) +Error: 8 - Undefined variable: unset_var, %s(%d) Arg value 10.5 -Error: 2 - parse_url(): Invalid URL component identifier 10, %s(71) +Error: 2 - parse_url(): Invalid URL component identifier 10, %s(%d) bool(false) Arg value -10.5 @@ -108,54 +108,38 @@ array(8) { } Arg value 101234567000 -array(8) { - ["scheme"]=> - string(4) "http" - ["host"]=> - string(11) "www.php.net" - ["port"]=> - int(80) - ["user"]=> - string(6) "secret" - ["pass"]=> - string(7) "hideout" - ["path"]=> - string(10) "/index.php" - ["query"]=> - string(31) "test=1&test2=char&test3=mixesCI" - ["fragment"]=> - string(16) "some_page_ref123" -} +Error: 2 - parse_url() expects parameter 2 to be long, double given, %s(%d) +NULL Arg value 1.07654321E-9 string(4) "http" Arg value 0.5 string(4) "http" -Error: 8 - Array to string conversion, %sparse_url_variation_002_32bit.php(%d) +Error: 8 - Array to string conversion, %s(%d) Arg value Array -Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(%d) NULL -Error: 8 - Array to string conversion, %sparse_url_variation_002_32bit.php(%d) +Error: 8 - Array to string conversion, %s(%d) Arg value Array -Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(%d) NULL -Error: 8 - Array to string conversion, %sparse_url_variation_002_32bit.php(%d) +Error: 8 - Array to string conversion, %s(%d) Arg value Array -Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(%d) NULL -Error: 8 - Array to string conversion, %sparse_url_variation_002_32bit.php(%d) +Error: 8 - Array to string conversion, %s(%d) Arg value Array -Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(%d) NULL -Error: 8 - Array to string conversion, %sparse_url_variation_002_32bit.php(%d) +Error: 8 - Array to string conversion, %s(%d) Arg value Array -Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, array given, %s(%d) NULL Arg value @@ -165,36 +149,36 @@ Arg value string(4) "http" Arg value 1 -string(11) "www.php.net" +string(%d) "www.php.net" Arg value string(4) "http" Arg value 1 -string(11) "www.php.net" +string(%d) "www.php.net" Arg value string(4) "http" Arg value -Error: 2 - parse_url() expects parameter 2 to be long, string given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, string given, %s(%d) NULL Arg value -Error: 2 - parse_url() expects parameter 2 to be long, string given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, string given, %s(%d) NULL Arg value string -Error: 2 - parse_url() expects parameter 2 to be long, string given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, string given, %s(%d) NULL Arg value string -Error: 2 - parse_url() expects parameter 2 to be long, string given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, string given, %s(%d) NULL -Error: 4096 - Object of class stdClass could not be converted to string, %s(70) +Error: 4096 - Object of class stdClass could not be converted to string, %s(%d) Arg value -Error: 2 - parse_url() expects parameter 2 to be long, object given, %s(71) +Error: 2 - parse_url() expects parameter 2 to be long, object given, %s(%d) NULL Arg value |