Skip to content

Commit 83788a2

Browse files
committed
Add test case for Bug #75785
1 parent 6fcca53 commit 83788a2

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

ext/exif/tests/bug75785/P1000506.JPG

6 MB
Loading

ext/exif/tests/bug75785/bug75785.phpt

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
--TEST--
2+
Bug #75785 fix corrupt EXIF header issues; Related to mixed endianness. (Thank you @Richard Matzinger for providing the test photo)
3+
--SKIPIF--
4+
<?php if (!extension_loaded('exif')) print 'skip exif extension not available';?>
5+
--FILE--
6+
<?php
7+
$mixedEndiannessFile = dirname(__FILE__).'/P1000506.JPG';
8+
$tags = exif_read_data($mixedEndiannessFile, 'EXIF', true, false);
9+
10+
echo $tags['GPS']['GPSLatitude'][0] . PHP_EOL;
11+
echo $tags['GPS']['GPSLongitude'][0] . PHP_EOL;
12+
?>
13+
===DONE===
14+
--EXPECTF--
15+
38/1
16+
122/1
17+
===DONE===

0 commit comments

Comments
 (0)