com php-src: fix GD tests with no GD loaded: ext/gd/tests/bug67248.phpt ext/gd/tests/imagegd2_nullbyte_injection.phpt ext/gd/
tests/imagegd_nullbyte_injection.phpt ext/gd/tests/imag egif_nullbyte_injection.phpt ext/gd/tests/imagejpeg_n ullbyte_injection.phpt
ext/gd/tests/imagepng_nullbyte _injection.phpt ext/gd/tests/imagewbmp_nullbyte_injec tion.phpt ext/gd/tests/imagewebp_nullbyte_injection.p hpt
| From: | Stanislav Malyshev | Date: | Mon, 05 Jan 2015 03:45:57 +0000 |
| Subject: | com php-src: fix GD tests with no GD loaded: ext/gd/tests/bug67248.phpt ext/gd/tests/imagegd2_nullbyte_injection.phpt ext/gd/ tests/imagegd_nullbyte_injection.phpt ext/gd/tests/imag egif_nullbyte_injection.phpt ext/gd/tests/imagejpeg_n ullbyte_injection.phpt ext/gd/tests/imagepng_nullbyte _injection.phpt ext/gd/tests/imagewbmp_nullbyte_injec tion.phpt ext/gd/tests/imagewebp_nullbyte_injection.p hpt |
||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-83975@lists.php.net to get a copy of this message | ||
Commit: 75f93ed663ce9b7e1f8742b6840505884a143682
Author: Stanislav Malyshev <stas@php.net> Sun, 4 Jan 2015 19:45:57 -0800
Parents: 4ed261870f5106b904577e394efa70fc5b689a1c
Branches: PHP-5.5 PHP-5.6 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=75f93ed663ce9b7e1f8742b6840505884a143682
Log:
fix GD tests with no GD loaded
Changed paths:
M ext/gd/tests/bug67248.phpt
M ext/gd/tests/imagegd2_nullbyte_injection.phpt
M ext/gd/tests/imagegd_nullbyte_injection.phpt
M ext/gd/tests/imagegif_nullbyte_injection.phpt
M ext/gd/tests/imagejpeg_nullbyte_injection.phpt
M ext/gd/tests/imagepng_nullbyte_injection.phpt
M ext/gd/tests/imagewbmp_nullbyte_injection.phpt
M ext/gd/tests/imagewebp_nullbyte_injection.phpt
Diff:
diff --git a/ext/gd/tests/bug67248.phpt b/ext/gd/tests/bug67248.phpt
index 9c83966..5cae5f8 100644
--- a/ext/gd/tests/bug67248.phpt
+++ b/ext/gd/tests/bug67248.phpt
@@ -2,7 +2,7 @@
Bug #67248 (imageaffinematrixget missing check of parameters)
--SKIPIF--
<?php
- if(!extension_loaded('gd')){ die('skip gd extension not available')}
+ if(!extension_loaded('gd')){ die('skip gd extension not available'); }
if(!function_exists('imageaffinematrixget')) die('skip
imageaffinematrixget() not available');
?>
--FILE--
diff --git a/ext/gd/tests/imagegd2_nullbyte_injection.phpt
b/ext/gd/tests/imagegd2_nullbyte_injection.phpt
index 49affef..278a4a8 100644
--- a/ext/gd/tests/imagegd2_nullbyte_injection.phpt
+++ b/ext/gd/tests/imagegd2_nullbyte_injection.phpt
@@ -1,5 +1,9 @@
--TEST--
Testing null byte injection in imagegd2
+--SKIPIF--
+<?php
+ if(!extension_loaded('gd')){ die('skip gd extension not available'); }
+?>
--CLEAN--
$tempdir = sys_get_temp_dir(). '/php-gdtest';
foreach (glob($tempdir . "/test*") as $file ) { unlink($file); }
diff --git a/ext/gd/tests/imagegd_nullbyte_injection.phpt
b/ext/gd/tests/imagegd_nullbyte_injection.phpt
index a423a55..1ef9354 100644
--- a/ext/gd/tests/imagegd_nullbyte_injection.phpt
+++ b/ext/gd/tests/imagegd_nullbyte_injection.phpt
@@ -1,5 +1,9 @@
--TEST--
Testing null byte injection in imagegd
+--SKIPIF--
+<?php
+ if(!extension_loaded('gd')){ die('skip gd extension not available'); }
+?>
--CLEAN--
$tempdir = sys_get_temp_dir(). '/php-gdtest';
foreach (glob($tempdir .. "/test*") as $file ) { unlink($file); }
diff --git a/ext/gd/tests/imagegif_nullbyte_injection.phpt
b/ext/gd/tests/imagegif_nullbyte_injection.phpt
index c3d0c30..44b1be1 100644
--- a/ext/gd/tests/imagegif_nullbyte_injection.phpt
+++ b/ext/gd/tests/imagegif_nullbyte_injection.phpt
@@ -6,6 +6,7 @@ foreach (glob($tempdir . "/test*") as $file ) { unlink($file); }
rmdir($tempdir);
--SKIPIF--
<?php
+if(!extension_loaded('gd')){ die('skip gd extension not available'); }
$support = gd_info();
if (!isset($support['GIF Create Support']) || $support['GIF Create Support']
=== false) {
print 'skip gif support not available';
diff --git a/ext/gd/tests/imagejpeg_nullbyte_injection.phpt
b/ext/gd/tests/imagejpeg_nullbyte_injection.phpt
index 9c52355..4a45fa3 100644
--- a/ext/gd/tests/imagejpeg_nullbyte_injection.phpt
+++ b/ext/gd/tests/imagejpeg_nullbyte_injection.phpt
@@ -6,6 +6,7 @@ foreach (glob($tempdir . "/test*") as $file ) { unlink($file); }
rmdir($tempdir);
--SKIPIF--
<?php
+if(!extension_loaded('gd')){ die('skip gd extension not available'); }
$support = gd_info();
if (!isset($support['JPEG Support']) || $support['JPEG Support'] === false) {
print 'skip jpeg support not available';
diff --git a/ext/gd/tests/imagepng_nullbyte_injection.phpt
b/ext/gd/tests/imagepng_nullbyte_injection.phpt
index 13949dc..9a5b7c3 100644
--- a/ext/gd/tests/imagepng_nullbyte_injection.phpt
+++ b/ext/gd/tests/imagepng_nullbyte_injection.phpt
@@ -6,6 +6,7 @@ foreach (glob($tempdir . "/test*") as $file ) { unlink($file); }
rmdir($tempdir);
--SKIPIF--
<?php
+if(!extension_loaded('gd')){ die('skip gd extension not available'); }
$support = gd_info();
if (!isset($support['PNG Support']) || $support['PNG Support'] === false) {
print 'skip png support not available';
diff --git a/ext/gd/tests/imagewbmp_nullbyte_injection.phpt
b/ext/gd/tests/imagewbmp_nullbyte_injection.phpt
index f199626..54a5749 100644
--- a/ext/gd/tests/imagewbmp_nullbyte_injection.phpt
+++ b/ext/gd/tests/imagewbmp_nullbyte_injection.phpt
@@ -6,6 +6,7 @@ foreach (glob($tempdir . "/test*") as $file ) { unlink($file); }
rmdir($tempdir);
--SKIPIF--
<?php
+if(!extension_loaded('gd')){ die('skip gd extension not available'); }
$support = gd_info();
if (!isset($support['WBMP Support']) || $support['WBMP Support'] === false) {
print 'skip wbmp support not available';
diff --git a/ext/gd/tests/imagewebp_nullbyte_injection.phpt
b/ext/gd/tests/imagewebp_nullbyte_injection.phpt
index 3bd6325..166beb1 100644
--- a/ext/gd/tests/imagewebp_nullbyte_injection.phpt
+++ b/ext/gd/tests/imagewebp_nullbyte_injection.phpt
@@ -6,6 +6,7 @@ foreach (glob($tempdir . "/test*") as $file ) { unlink($file); }
rmdir($tempdir);
--SKIPIF--
<?php
+if(!extension_loaded('gd')){ die('skip gd extension not available'); }
$support = gd_info();
if (!isset($support['WEBP Support']) || $support['WEBP Support'] === false) {
print 'skip webp support not available';