summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2021-02-08 08:30:04 +0300
committerAndrew Dolgov <[email protected]>2021-02-08 08:30:04 +0300
commit479da5aa868d791b4c680e1f10a89e8f075efc10 (patch)
treef0bb29d2c23f95d300a93d27c210c52deb961503 /lib
parent3f972f8fede4ef2d1c47f9c55b5ca7b9a92dfd9c (diff)
jimIcon: hide GD warning
Diffstat (limited to 'lib')
-rw-r--r--lib/jimIcon.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/jimIcon.php b/lib/jimIcon.php
index d976c808b..cee1a7bad 100644
--- a/lib/jimIcon.php
+++ b/lib/jimIcon.php
@@ -104,7 +104,12 @@ class jimIcon {
}
// See if we can parse it (might be PNG format here)
- $i = @imagecreatefromstring($data);
+ // (all this to hide one GD warning)
+ $er = error_reporting();
+ error_reporting(0);
+ $i = imagecreatefromstring($data);
+ error_reporting($er);
+
if ($i) {
imagesavealpha($i, true);
return $i;