Title: [90369] trunk/Source/WebCore
Revision
90369
Author
[email protected]
Date
2011-07-04 11:16:34 -0700 (Mon, 04 Jul 2011)

Log Message

2011-07-04  Jeff Timanus  <[email protected]>

        Reviewed by Stephen White.

        Prevent calls to GrapicsContext3D::deleteTexture with id 0 in DrawingBuffer::clear().
        https://bugs.webkit.org/show_bug.cgi?id=63756

        * platform/graphics/gpu/DrawingBuffer.cpp:
        (WebCore::DrawingBuffer::clear):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (90368 => 90369)


--- trunk/Source/WebCore/ChangeLog	2011-07-04 18:03:56 UTC (rev 90368)
+++ trunk/Source/WebCore/ChangeLog	2011-07-04 18:16:34 UTC (rev 90369)
@@ -1,3 +1,13 @@
+2011-07-04  Jeff Timanus  <[email protected]>
+
+        Reviewed by Stephen White.
+
+        Prevent calls to GrapicsContext3D::deleteTexture with id 0 in DrawingBuffer::clear().
+        https://bugs.webkit.org/show_bug.cgi?id=63756
+
+        * platform/graphics/gpu/DrawingBuffer.cpp:
+        (WebCore::DrawingBuffer::clear):
+
 2011-07-04  Martin Robinson  <[email protected]>
 
         Reviewed by Andreas Kling.

Modified: trunk/Source/WebCore/platform/graphics/gpu/DrawingBuffer.cpp (90368 => 90369)


--- trunk/Source/WebCore/platform/graphics/gpu/DrawingBuffer.cpp	2011-07-04 18:03:56 UTC (rev 90368)
+++ trunk/Source/WebCore/platform/graphics/gpu/DrawingBuffer.cpp	2011-07-04 18:16:34 UTC (rev 90369)
@@ -58,36 +58,39 @@
 {
     if (!m_context)
         return;
-        
+
     m_context->makeContextCurrent();
-    m_context->deleteTexture(m_colorBuffer);
-    m_colorBuffer = 0;
-    
+
+    if (m_colorBuffer) {
+        m_context->deleteTexture(m_colorBuffer);
+        m_colorBuffer = 0;
+    }
+
     if (m_multisampleColorBuffer) {
         m_context->deleteRenderbuffer(m_multisampleColorBuffer);
         m_multisampleColorBuffer = 0;
     }
-    
+
     if (m_depthStencilBuffer) {
         m_context->deleteRenderbuffer(m_depthStencilBuffer);
         m_depthStencilBuffer = 0;
     }
-    
+
     if (m_depthBuffer) {
         m_context->deleteRenderbuffer(m_depthBuffer);
         m_depthBuffer = 0;
     }
-    
+
     if (m_stencilBuffer) {
         m_context->deleteRenderbuffer(m_stencilBuffer);
         m_stencilBuffer = 0;
     }
-    
+
     if (m_multisampleFBO) {
         m_context->deleteFramebuffer(m_multisampleFBO);
         m_multisampleFBO = 0;
     }
-        
+
     m_context->deleteFramebuffer(m_fbo);
     m_fbo = 0;
 }
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to