Index: Source/platform/graphics/gpu/DrawingBuffer.cpp |
diff --git a/Source/platform/graphics/gpu/DrawingBuffer.cpp b/Source/platform/graphics/gpu/DrawingBuffer.cpp |
index 0ec4bf9179012c1217b92aa3362f4f7d02e1e9df..2f6340ba22f2cdff9e74c9f816d4963862855109 100644 |
--- a/Source/platform/graphics/gpu/DrawingBuffer.cpp |
+++ b/Source/platform/graphics/gpu/DrawingBuffer.cpp |
@@ -276,9 +276,9 @@ bool DrawingBuffer::prepareMailbox(blink::WebExternalTextureMailbox* outMailbox, |
return true; |
} |
-void DrawingBuffer::mailboxReleased(const blink::WebExternalTextureMailbox& mailbox) |
+void DrawingBuffer::mailboxReleased(const blink::WebExternalTextureMailbox& mailbox, bool lostResource) |
{ |
- if (m_destructionInProgress) { |
+ if (m_destructionInProgress && !m_context->isContextLost()) { |
mailboxReleasedWhileDestructionInProgress(mailbox); |
return; |
} |
@@ -289,7 +289,8 @@ void DrawingBuffer::mailboxReleased(const blink::WebExternalTextureMailbox& mail |
mailboxInfo->mailbox.syncPoint = mailbox.syncPoint; |
ASSERT(mailboxInfo->m_parentDrawingBuffer.get() == this); |
mailboxInfo->m_parentDrawingBuffer.clear(); |
- m_recycledMailboxQueue.prepend(mailboxInfo->mailbox); |
+ if (!m_context->isContextLost()) |
+ m_recycledMailboxQueue.prepend(mailboxInfo->mailbox); |
return; |
} |
} |