| Index: third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.cpp
|
| diff --git a/third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.cpp b/third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.cpp
|
| index a23eca72c8799ea6cd5eec4adbb2d6cc646eccbf..8ddc6e4dae6316b5705cdd04bfe55bbd79339078 100644
|
| --- a/third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.cpp
|
| +++ b/third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.cpp
|
| @@ -117,11 +117,12 @@ bool BMPImageReader::decodeBMP(bool onlySize) {
|
| // Initialize the framebuffer if needed.
|
| DCHECK(m_buffer); // Parent should set this before asking us to decode!
|
| if (m_buffer->getStatus() == ImageFrame::FrameEmpty) {
|
| - if (!m_buffer->setSizeAndColorSpace(m_parent->size().width(),
|
| + if (!m_buffer->allocateBackingStore(m_parent->size().width(),
|
| m_parent->size().height(),
|
| m_parent->colorSpaceForSkImages())) {
|
| return m_parent->setFailed(); // Unable to allocate.
|
| }
|
| + m_buffer->zeroFillPixelData();
|
| m_buffer->setStatus(ImageFrame::FramePartial);
|
| // setSize() calls eraseARGB(), which resets the alpha flag, so we force
|
| // it back to false here. We'll set it true below in all cases where
|
|
|