⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 268835 in webkit


Ignore:
Timestamp:
Oct 21, 2020, 3:16:00 PM (6 years ago)
Author:
Alan Coon
Message:

Cherry-pick r268701. rdar://problem/70541911

Fix possible crash in GraphicsLayerCA::computeVisibleAndCoverageRect()
https://bugs.webkit.org/show_bug.cgi?id=217930
<rdar://problem/70316943>

Reviewed by Tim Horton.

If we made a m_overflowControlsHostLayerAncestorClippingStack, make sure we unparent
its layers when tearing down the RenderLayerBacking, and when we determine that we
longer need a m_ancestorClippingStack (having a m_overflowControlsHostLayerAncestorClippingStack
implies that we have a m_ancestorClippingStack).

  • rendering/RenderLayerBacking.cpp: (WebCore::RenderLayerBacking::destroyGraphicsLayers): (WebCore::RenderLayerBacking::updateAncestorClipping):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@268701 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Location:
branches/safari-610-branch/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/safari-610-branch/Source/WebCore/ChangeLog

    r268832 r268835  
     12020-10-21  Russell Epstein  <repstein@apple.com>
     2
     3        Cherry-pick r268701. rdar://problem/70541911
     4
     5    Fix possible crash in GraphicsLayerCA::computeVisibleAndCoverageRect()
     6    https://bugs.webkit.org/show_bug.cgi?id=217930
     7    <rdar://problem/70316943>
     8   
     9    Reviewed by Tim Horton.
     10   
     11    If we made a m_overflowControlsHostLayerAncestorClippingStack, make sure we unparent
     12    its layers when tearing down the RenderLayerBacking, and when we determine that we
     13    longer need a m_ancestorClippingStack (having a m_overflowControlsHostLayerAncestorClippingStack
     14    implies that we have a m_ancestorClippingStack).
     15   
     16    * rendering/RenderLayerBacking.cpp:
     17    (WebCore::RenderLayerBacking::destroyGraphicsLayers):
     18    (WebCore::RenderLayerBacking::updateAncestorClipping):
     19   
     20    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@268701 268f45cc-cd09-0410-ab3c-d52691b4dbfc
     21
     22    2020-10-19  Simon Fraser  <simon.fraser@apple.com>
     23
     24            Fix possible crash in GraphicsLayerCA::computeVisibleAndCoverageRect()
     25            https://bugs.webkit.org/show_bug.cgi?id=217930
     26            <rdar://problem/70316943>
     27
     28            Reviewed by Tim Horton.
     29
     30            If we made a m_overflowControlsHostLayerAncestorClippingStack, make sure we unparent
     31            its layers when tearing down the RenderLayerBacking, and when we determine that we
     32            longer need a m_ancestorClippingStack (having a m_overflowControlsHostLayerAncestorClippingStack
     33            implies that we have a m_ancestorClippingStack).
     34
     35            * rendering/RenderLayerBacking.cpp:
     36            (WebCore::RenderLayerBacking::destroyGraphicsLayers):
     37            (WebCore::RenderLayerBacking::updateAncestorClipping):
     38
    1392020-10-21  Russell Epstein  <repstein@apple.com>
    240
  • branches/safari-610-branch/Source/WebCore/rendering/RenderLayerBacking.cpp

    r267633 r268835  
    584584    GraphicsLayer::clear(m_maskLayer);
    585585
    586     if (m_ancestorClippingStack) {
    587         for (auto& entry : m_ancestorClippingStack->stack())
    588             GraphicsLayer::unparentAndClear(entry.clippingLayer);
    589     }
     586    if (m_ancestorClippingStack)
     587        removeClippingStackLayers(*m_ancestorClippingStack);
     588
     589    if (m_overflowControlsHostLayerAncestorClippingStack)
     590        removeClippingStackLayers(*m_overflowControlsHostLayerAncestorClippingStack);
    590591
    591592    GraphicsLayer::unparentAndClear(m_contentsContainmentLayer);
     
    19381939    } else if (m_ancestorClippingStack) {
    19391940        removeClippingStackLayers(*m_ancestorClippingStack);
    1940 
    19411941        m_ancestorClippingStack = nullptr;
     1942       
     1943        if (m_overflowControlsHostLayerAncestorClippingStack) {
     1944            removeClippingStackLayers(*m_overflowControlsHostLayerAncestorClippingStack);
     1945            m_overflowControlsHostLayerAncestorClippingStack = nullptr;
     1946        }
     1947       
    19421948        layersChanged = true;
    19431949    }
Note: See TracChangeset for help on using the changeset viewer.