From 06ed4e03676ca8087cc40ca3d018b96a055a3b96 Mon Sep 17 00:00:00 2001 From: hugetoad Date: Sun, 11 Jan 2004 08:36:56 +0000 Subject: Better check for function imagecreatetruecolor() git-svn-id: svn://svn.zabbix.com/trunk@1167 97f52cf1-0a1b-0410-bd0e-c28be96e8082 --- frontends/php/map.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'frontends/php/map.php') diff --git a/frontends/php/map.php b/frontends/php/map.php index 4d60c7a6..56e60937 100644 --- a/frontends/php/map.php +++ b/frontends/php/map.php @@ -40,7 +40,7 @@ check_authorisation(); - if(function_exists("imagecreatetruecolor")) + if(function_exists("imagecreatetruecolor")&&@imagecreatetruecolor(1,1)) { $im = imagecreatetruecolor($width,$height); } @@ -135,7 +135,7 @@ $x2=DBget_field($result1,0,0); $y2=DBget_field($result1,0,1); - if(function_exists("imagecreatetruecolor")) + if(function_exists("imagecreatetruecolor")&&@imagecreatetruecolor(1,1)) { $size=48/2; } @@ -203,7 +203,7 @@ if(@gettype($icons["$icon"])!="resource") { - if(function_exists("imagecreatetruecolor")) + if(function_exists("imagecreatetruecolor")&&@imagecreatetruecolor(1,1)) { $icons[$icon]=ImageCreateFromPNG("images/sysmaps/$icon.png"); } -- cgit