xref: /PHP-7.1/ext/spl/tests/bug52573.phpt (revision 2fb2f815)
1--TEST--
2Bug #52573 (SplFileObject::fscanf Segmentation fault)
3--FILE--
4<?php // test
5
6$result = null;
7$f = new SplFileObject(__FILE__, 'r');
8var_dump($f->fscanf('<?php // %s', $result));
9var_dump($result);
10var_dump($f->fscanf('<?php // %s'));
11?>
12--EXPECTF--
13int(1)
14string(4) "test"
15array(1) {
16  [0]=>
17  NULL
18}
19