Skip to content

Commit

Permalink
Merge pull request SDWebImage#1167 from jiangmingz/patch-2
Browse files Browse the repository at this point in the history
fix ImageIO: CGImageSourceCreateWithData data parameter is nil
  • Loading branch information
mythodeia committed Jun 24, 2015
2 parents 7692bd2 + be07912 commit 08e9962
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions SDWebImage/UIImage+MultiFormat.m
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@
@implementation UIImage (MultiFormat)

+ (UIImage *)sd_imageWithData:(NSData *)data {
if (!data) {
return nil;
}

UIImage *image;
NSString *imageContentType = [NSData sd_contentTypeForImageData:data];
if ([imageContentType isEqualToString:@"image/gif"]) {
Expand Down

0 comments on commit 08e9962

Please sign in to comment.