diff options
author | Robin Appelman <icewind@owncloud.com> | 2012-03-26 23:56:07 +0200 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2012-03-26 23:56:07 +0200 |
commit | eb3ec05f882ec54cc19009966e62feb31f5577a4 (patch) | |
tree | a4a14e125b73d69aa9b2baaa5f60d0f6c5f39f32 /apps/gallery | |
parent | 73c6db5c8e6d876adf7b6c1c91049c66be26ba87 (diff) | |
download | nextcloud-server-eb3ec05f882ec54cc19009966e62feb31f5577a4.tar.gz nextcloud-server-eb3ec05f882ec54cc19009966e62feb31f5577a4.zip |
fix gallery scan when an image cant be loaded
Diffstat (limited to 'apps/gallery')
-rw-r--r-- | apps/gallery/lib/scanner.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/gallery/lib/scanner.php b/apps/gallery/lib/scanner.php index 6d2d44d428f..0317f943e5d 100644 --- a/apps/gallery/lib/scanner.php +++ b/apps/gallery/lib/scanner.php @@ -78,8 +78,8 @@ class OC_Gallery_Scanner { $image = OC_Gallery_Photo::getThumbnail($files[$i]); if ($image && $image->valid()) { imagecopyresampled($thumbnail, $image->resource(), $i*200, 0, 0, 0, 200, 200, 200, 200); + $image->destroy(); } - $image->destroy(); } imagepng($thumbnail, OC_Config::getValue("datadirectory").'/'. OC_User::getUser() .'/gallery/' . $albumName.'.png'); imagedestroy($thumbnail); |