Index: third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp |
diff --git a/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp b/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp |
index 55967fe42a2d60b290640c12cc70e024e742d8ed..a9c898469e5fd847cdd14895c6d4f72aee46e878 100644 |
--- a/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp |
+++ b/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp |
@@ -602,7 +602,7 @@ bool Canvas2DLayerBridge::prepareMailbox(WebExternalTextureMailbox* outMailbox, |
} |
RefPtr<SkImage> image = newImageSnapshot(PreferAcceleration); |
- if (!image) |
+ if (!image || !image->getTexture()) |
return false; |
WebGraphicsContext3D* webContext = context(); |
@@ -631,8 +631,6 @@ bool Canvas2DLayerBridge::prepareMailbox(WebExternalTextureMailbox* outMailbox, |
// Need to flush skia's internal queue because texture is about to be accessed directly |
grContext->flush(); |
- ASSERT(image->getTexture()); |
- |
// Because of texture sharing with the compositor, we must invalidate |
// the state cached in skia so that the deferred copy on write |
// in SkSurface_Gpu does not make any false assumptions. |