summaryrefslogtreecommitdiffstats
path: root/350.patch
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2020-09-28 15:53:19 +0200
committerRemi Collet <remi@remirepo.net>2020-09-28 15:53:19 +0200
commitfb8dc6bde64bede6186edb611e324a6001873109 (patch)
tree076bc0dc26664641eb52d802edf7b01a7e8db386 /350.patch
parent94abfd85fee63633104a6b4410a050ff7637b53a (diff)
add patch for test suite with PHP 8 from
https://github.com/Imagick/imagick/pull/350 simpler warning
Diffstat (limited to '350.patch')
-rw-r--r--350.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/350.patch b/350.patch
new file mode 100644
index 0000000..964cc72
--- /dev/null
+++ b/350.patch
@@ -0,0 +1,29 @@
+From 4ace7cf1db75577e9c8eeb4826c9a04ac9bef4a9 Mon Sep 17 00:00:00 2001
+From: Remi Collet <remi@remirepo.net>
+Date: Mon, 28 Sep 2020 15:06:14 +0200
+Subject: [PATCH] simpler warning to avoid DivisionByZeroError exception in 8
+
+---
+ tests/270_imagick_restoreErrorHandler.phpt | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/tests/270_imagick_restoreErrorHandler.phpt b/tests/270_imagick_restoreErrorHandler.phpt
+index 77eeb17..ba2f5d1 100644
+--- a/tests/270_imagick_restoreErrorHandler.phpt
++++ b/tests/270_imagick_restoreErrorHandler.phpt
+@@ -16,7 +16,7 @@ catch(ImagickException $ie) {
+ }
+
+ try {
+- $x = @(5 / 0);
++ $x = @$x;
+ echo "Normal warning is suppressed".PHP_EOL;
+ }
+ catch(\Exception $e) {
+@@ -27,4 +27,4 @@ catch(\Exception $e) {
+ ?>
+ --EXPECTF--
+ Normal exception
+-Normal warning is suppressed
+\ No newline at end of file
++Normal warning is suppressed