xref: /PHP-7.3/ext/standard/tests/image/bug72278.phpt (revision b746e698)
1--TEST--
2Bug #72278 (getimagesize returning FALSE on valid jpg)
3--FILE--
4<?php
5define('FILENAME', __DIR__ . DIRECTORY_SEPARATOR . 'bug72278.jpg');
6
7var_dump(getimagesize(FILENAME));
8?>
9===DONE===
10--EXPECTF--
11Warning: getimagesize(): corrupt JPEG data: 3 extraneous bytes before marker in %s%ebug72278.php on line %d
12array(7) {
13  [0]=>
14  int(300)
15  [1]=>
16  int(300)
17  [2]=>
18  int(2)
19  [3]=>
20  string(24) "width="300" height="300""
21  ["bits"]=>
22  int(8)
23  ["channels"]=>
24  int(3)
25  ["mime"]=>
26  string(10) "image/jpeg"
27}
28===DONE===
29