Index: tools/get_images_from_skps.cpp |
diff --git a/tools/get_images_from_skps.cpp b/tools/get_images_from_skps.cpp |
index a78c412a1bf35f07742cde2de9d43c9aa1145679..11b99c214d1f9b5ea3753057033603ae23d60807 100644 |
--- a/tools/get_images_from_skps.cpp |
+++ b/tools/get_images_from_skps.cpp |
@@ -82,7 +82,9 @@ struct Sniffer : public SkPixelSerializer { |
SkBitmap bitmap; |
SkImageInfo info = codec->getInfo().makeColorType(kN32_SkColorType); |
bitmap.allocPixels(info); |
- if (SkCodec::kSuccess != codec->getPixels(info, bitmap.getPixels(), bitmap.rowBytes())) |
+ const SkCodec::Result result = codec->getPixels( |
+ info, bitmap.getPixels(), bitmap.rowBytes()); |
+ if (SkCodec::kIncompleteInput != result && SkCodec::kSuccess != result) |
{ |
SkDebugf("Decoding failed for %s\n", skpName.c_str()); |
gSkpToUnknownCount[skpName]++; |