浏览代码

Fix runtime exception

(cherry picked from commit 03a0766155bd1d03d5caba98da61af491740c1d3)
Felix Paul Kühne 9 年之前
父节点
当前提交
d092b7ced4
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      Sources/VLCThumbnailsCache.m

+ 2 - 1
Sources/VLCThumbnailsCache.m

@@ -306,7 +306,8 @@
         CGFloat centerOffset = (imagePartWidth * i + imagePartWidth / 2) - imageSize.width / 2;
         //shift the rect to draw the middle of the image in the clippingrect
         CGRect drawingRect = CGRectMake(centerOffset, 0, imageSize.width, imageSize.height);
-        [clusterThumb drawInRect:drawingRect];
+        if (clusterThumb != nil)
+            [clusterThumb drawInRect:drawingRect];
         //get rid of the old clippingRect
         CGContextRestoreGState(context);
     }