xref: /PHP-7.3/ext/bz2/tests/bug72447.phpt (revision de1c4073)
1--TEST--
2Bug #72447: Type Confusion in php_bz2_filter_create()
3--SKIPIF--
4<?php if (!extension_loaded("bz2")) print "skip"; ?>
5--FILE--
6<?php
7$input = "AAAAAAAA";
8$param = array('blocks' => $input);
9
10$fp = fopen('testfile', 'w');
11stream_filter_append($fp, 'bzip2.compress', STREAM_FILTER_WRITE, $param);
12fclose($fp);
13?>
14--EXPECTF--
15Warning: stream_filter_append(): Invalid parameter given for number of blocks to allocate. (0) in %s%ebug72447.php on line %d
16