From 918a85e721ca105e3c11d4b211e5ff6dda4c4a4f Mon Sep 17 00:00:00 2001 From: shish Date: Wed, 2 Jan 2008 22:24:12 +0000 Subject: [PATCH] cleaner error for dead thumbs git-svn-id: file:///home/shish/svn/shimmie2/branches/branch_2.1@681 7f39781d-f577-437e-ae19-be835c7a54ca --- ext/image/main.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ext/image/main.php b/ext/image/main.php index 7f3ca750..c90ab4ba 100644 --- a/ext/image/main.php +++ b/ext/image/main.php @@ -244,6 +244,11 @@ class ImageIO extends Extension { $file = $image->get_image_filename(); } + if(!file_exists($file)) { + print("Can't read $file"); + exit; + } + $page->set_data(file_get_contents($file)); if(isset($_SERVER["HTTP_IF_MODIFIED_SINCE"])) {