Merge pull request #840 from foxling/master

fix #610 display progressive jpeg issue
This commit is contained in:
Bogdan Poplauschi 2014-10-31 20:12:38 +02:00
commit 1a3ccc2e8d
1 changed files with 1 additions and 2 deletions

View File

@ -228,8 +228,7 @@
const NSInteger totalSize = self.imageData.length;
// Update the data source, we must pass ALL the data, not just the new bytes
CGImageSourceRef imageSource = CGImageSourceCreateIncremental(NULL);
CGImageSourceUpdateData(imageSource, (__bridge CFDataRef)self.imageData, totalSize == self.expectedSize);
CGImageSourceRef imageSource = CGImageSourceCreateWithData((__bridge CFDataRef)self.imageData, NULL);
if (width + height == 0) {
CFDictionaryRef properties = CGImageSourceCopyPropertiesAtIndex(imageSource, 0, NULL);