blob: b34be23267851a7457721f9248cfa493104ba66c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
--TEST--
Test unpack() function : error conditions
--FILE--
<?php
/* Prototype : array unpack ( string $format , string $data )
* Description: Unpack data from binary string
* Source code: ext/standard/pack.c
*/
echo "*** Testing unpack() : error conditions ***\n";
echo "\n-- Testing unpack() function with invalid format character --\n";
$extra_arg = 10;
var_dump(unpack("B", pack("I", 65534)));
?>
===DONE===
--EXPECTF--
*** Testing unpack() : error conditions ***
-- Testing unpack() function with invalid format character --
Warning: unpack(): Invalid format type B in %s on line %d
bool(false)
===DONE===
|