Authored by sukeban

Protect against malformed image

Don’t add nil to the array, just skip the frame.
... ... @@ -32,6 +32,8 @@
for (size_t i = 0; i < count; i++) {
CGImageRef image = CGImageSourceCreateImageAtIndex(source, i, NULL);
if (!image)
continue;
duration += [self sd_frameDurationAtIndex:i source:source];
... ...