Index: src/codec/SkBmpCodec.cpp |
diff --git a/src/codec/SkBmpCodec.cpp b/src/codec/SkBmpCodec.cpp |
index 191c2ad8009cbc39e713a2a56452e632a7e84012..aff54021a7a3b4d30b237b6d89a0d99a3caf36d5 100644 |
--- a/src/codec/SkBmpCodec.cpp |
+++ b/src/codec/SkBmpCodec.cpp |
@@ -481,6 +481,8 @@ bool SkBmpCodec::ReadHeader(SkStream* stream, bool inIco, SkCodec** codecOut) { |
// Return the codec |
switch (inputFormat) { |
case kStandard_BmpInputFormat: |
+ // We require streams to have a memory base for Bmp-in-Ico decodes. |
+ SkASSERT(!inIco || nullptr != stream->getMemoryBase()); |
*codecOut = new SkBmpStandardCodec(imageInfo, stream, bitsPerPixel, numColors, |
bytesPerColor, offset - bytesRead, rowOrder, inIco); |
return true; |