summaryrefslogtreecommitdiff
path: root/ext/standard/tests/image
diff options
context:
space:
mode:
authorChristoph M. Becker <cmb@php.net>2015-07-23 18:40:54 +0200
committerChristoph M. Becker <cmb@php.net>2015-07-23 18:40:54 +0200
commitde3f60d5362629de810d640400aba0d4e37de1f0 (patch)
treef85d6cf530bf43b21fccd14ed2913d891b0689f6 /ext/standard/tests/image
parent084a6e43cd78546168133c066c236fc82c110a43 (diff)
parent35e717e12ef5be57f4a013208f5b25b617b3de02 (diff)
downloadphp-git-de3f60d5362629de810d640400aba0d4e37de1f0.tar.gz
Merge branch 'PHP-5.6'
* PHP-5.6: Fix #70052: getimagesize() fails for very large and very small WBMP Conflicts: ext/standard/image.c
Diffstat (limited to 'ext/standard/tests/image')
-rw-r--r--ext/standard/tests/image/bug70052.phpt21
-rw-r--r--ext/standard/tests/image/bug70052_1.wbmpbin0 -> 12 bytes
-rw-r--r--ext/standard/tests/image/bug70052_2.wbmpbin0 -> 7 bytes
3 files changed, 21 insertions, 0 deletions
diff --git a/ext/standard/tests/image/bug70052.phpt b/ext/standard/tests/image/bug70052.phpt
new file mode 100644
index 0000000000..76ebda92b2
--- /dev/null
+++ b/ext/standard/tests/image/bug70052.phpt
@@ -0,0 +1,21 @@
+--TEST--
+Bug #70052 (getimagesize() fails for very large and very small WBMP)
+--FILE--
+<?php
+var_dump(getimagesize(__DIR__ . '/bug70052_1.wbmp'));
+var_dump(getimagesize(__DIR__ . '/bug70052_2.wbmp'));
+?>
+--EXPECT--
+bool(false)
+array(5) {
+ [0]=>
+ int(3)
+ [1]=>
+ int(3)
+ [2]=>
+ int(15)
+ [3]=>
+ string(20) "width="3" height="3""
+ ["mime"]=>
+ string(18) "image/vnd.wap.wbmp"
+}
diff --git a/ext/standard/tests/image/bug70052_1.wbmp b/ext/standard/tests/image/bug70052_1.wbmp
new file mode 100644
index 0000000000..2c32f379ae
--- /dev/null
+++ b/ext/standard/tests/image/bug70052_1.wbmp
Binary files differ
diff --git a/ext/standard/tests/image/bug70052_2.wbmp b/ext/standard/tests/image/bug70052_2.wbmp
new file mode 100644
index 0000000000..d0f4313fc1
--- /dev/null
+++ b/ext/standard/tests/image/bug70052_2.wbmp
Binary files differ