[SCM] WebKit Debian packaging branch, webkit-1.3, updated. upstream/1.3.7-4207-g178b198

enne at google.com enne at google.com
Mon Feb 21 00:05:21 UTC 2011


The following commit has been merged in the webkit-1.3 branch:
commit 9c62f7e7bcc2dc599f88b10afd0d0947242100a5
Author: enne at google.com <enne at google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri Jan 28 00:50:34 2011 +0000

    2011-01-27  Adrienne Walker  <enne at google.com>
    
            Reviewed by James Robinson.
    
            [chromium] Tiled compositor crashes if compositing turned off mid-paint
            https://bugs.webkit.org/show_bug.cgi?id=53198
    
            * platform/graphics/chromium/LayerRendererChromium.cpp:
            (WebCore::LayerRendererChromium::drawLayers):
            * platform/graphics/chromium/LayerTilerChromium.cpp:
            (WebCore::LayerTilerChromium::update):
            (WebCore::LayerTilerChromium::draw):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@76864 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog
index 8780755..f6aa96f 100644
--- a/Source/WebCore/ChangeLog
+++ b/Source/WebCore/ChangeLog
@@ -1,3 +1,16 @@
+2011-01-27  Adrienne Walker  <enne at google.com>
+
+        Reviewed by James Robinson.
+
+        [chromium] Tiled compositor crashes if compositing turned off mid-paint
+        https://bugs.webkit.org/show_bug.cgi?id=53198
+
+        * platform/graphics/chromium/LayerRendererChromium.cpp:
+        (WebCore::LayerRendererChromium::drawLayers):
+        * platform/graphics/chromium/LayerTilerChromium.cpp:
+        (WebCore::LayerTilerChromium::update):
+        (WebCore::LayerTilerChromium::draw):
+
 2011-01-27  Carol Szabo <carol.szabo at nokia.com>
 
         Reviewed by David Hyatt.
diff --git a/Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp b/Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp
index 601f13c..c2accfd 100644
--- a/Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp
+++ b/Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp
@@ -265,6 +265,11 @@ void LayerRendererChromium::drawLayers(const IntRect& visibleRect, const IntRect
     // Re-enable color writes to layers, which may be partially transparent.
     m_context->colorMask(true, true, true, true);
 
+    // Recheck that we still have a root layer.  This may become null if
+    // compositing gets turned off during a paint operation.
+    if (!m_rootLayer)
+        return;
+
     // Set the root visible/content rects --- used by subsequent drawLayers calls.
     m_rootVisibleRect = visibleRect;
     m_rootContentRect = contentRect;
diff --git a/Source/WebCore/platform/graphics/chromium/LayerTilerChromium.cpp b/Source/WebCore/platform/graphics/chromium/LayerTilerChromium.cpp
index 6b65e66..3b179b6 100644
--- a/Source/WebCore/platform/graphics/chromium/LayerTilerChromium.cpp
+++ b/Source/WebCore/platform/graphics/chromium/LayerTilerChromium.cpp
@@ -299,6 +299,10 @@ void LayerTilerChromium::update(TilePaintInterface& painter, const IntRect& cont
 #error "Need to implement for your platform."
 #endif
 
+    // Painting could cause compositing to get turned off, which may cause the tiler to become invalidated mid-update.
+    if (!m_tiles.size())
+        return;
+
     for (int j = top; j <= bottom; ++j) {
         for (int i = left; i <= right; ++i) {
             Tile* tile = m_tiles[tileIndex(i, j)].get();
@@ -357,7 +361,7 @@ void LayerTilerChromium::setLayerPosition(const IntPoint& layerPosition)
 
 void LayerTilerChromium::draw(const IntRect& contentRect)
 {
-    if (m_skipsDraw)
+    if (m_skipsDraw || !m_tiles.size())
         return;
 
     // We reuse the shader program used by ContentLayerChromium.

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list