From 1d3f6cb0f862ca36dd44f4ff7d8a1c5768d34a43 Mon Sep 17 00:00:00 2001 From: garvinhicking Date: Mon, 11 Feb 2008 17:52:47 +0000 Subject: [PATCH] bail out if thumbs are smaller than 1 px (0=off) --- include/functions_images.inc.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/functions_images.inc.php b/include/functions_images.inc.php index 8a8ba2b..2841fb8 100644 --- a/include/functions_images.inc.php +++ b/include/functions_images.inc.php @@ -609,6 +609,10 @@ function serendipity_makeThumbnail($file, $directory = '', $size = false, $thumb if ($size === false) { $size = $serendipity['thumbSize']; } + + if ($size < 1) { + return array(0,0); + } if ($thumbname === false) { $thumbname = $serendipity['thumbSuffix']; -- 2.39.5