diff options
-rw-r--r-- | it.class | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -562,9 +562,10 @@ static function imageconvert($p) $type = strtr($type, array("jpeg" => "jpg", "tiff" => "tif", "ps" => "eps", "ept" => "eps")); $p += array('type' => $type, 'types' => "bmp,eps,gif,jp2,jpg,png,svg,tif"); $p['-opts'] = array('-thumbnail' => $p['size']) + (array)$p['-opts']; + $ultratimeout = file_exists("/opt/ultra/bin/ultratimeout") ? "/opt/ultra/bin/ultratimeout 600 " : ""; if (in_array($type, explode(',', $p['types']))) # Valid type? - $cmdoutput = it::exec('ultratimeout 600 gm convert 2>&1 -flatten -quality 75 {-opts} {in} {type}:{out} || echo "SHELL ERROR $?"', $p); + $cmdoutput = it::exec($ultratimeout . 'gm convert 2>&1 -flatten -quality 75 {-opts} {in} {type}:{out} || echo "SHELL ERROR $?"', $p); return $cmdoutput === ""; } |