Annotation of embedaddon/php/ext/standard/tests/strings/bug35817.phpt, revision 1.1.1.1

1.1       misho       1: --TEST--
                      2: Bug #35817 (unpack() does not decode odd number of hexadecimal values)
                      3: --FILE--
                      4: <?php
                      5: $a = pack("H3","181");
                      6: $b = unpack("H3", $a);
                      7: var_dump($b);
                      8: 
                      9: $a = pack("H2","18");
                     10: $b = unpack("H2", $a);
                     11: var_dump($b);
                     12: 
                     13: $a = pack("H","1");
                     14: $b = unpack("H", $a);
                     15: var_dump($b);
                     16: ?>
                     17: --EXPECT--
                     18: array(1) {
                     19:   [1]=>
                     20:   string(3) "181"
                     21: }
                     22: array(1) {
                     23:   [1]=>
                     24:   string(2) "18"
                     25: }
                     26: array(1) {
                     27:   [1]=>
                     28:   string(1) "1"
                     29: }

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>