Title: [282947] branches/safari-612-branch/Source/WebCore
Revision
282947
Author
repst...@apple.com
Date
2021-09-22 22:34:12 -0700 (Wed, 22 Sep 2021)

Log Message

Cherry-pick r282047. rdar://problem/83430148

    Ensure fragmented flow state invalidation even when the cached fragmented flow is not present.
    https://bugs.webkit.org/show_bug.cgi?id=229914
    <rdar://82025006>

    Reviewed by Antti Koivisto.

    The cached fragmented flow is the byproduct of querying the enclosing fragment during layout/repaint.
    Sometimes when the layout process, between 2 subsequent style change does not generate such cached fragmented flows
    the invalidation process stops early and leaves subtrees in an inconsistent state.

    Let's use the passed in fragmented flow when the cached value is not present.

    * rendering/RenderBlock.cpp:
    (WebCore::RenderBlock::resetEnclosingFragmentedFlowAndChildInfoIncludingDescendants):

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

Modified Paths

Diff

Modified: branches/safari-612-branch/Source/WebCore/ChangeLog (282946 => 282947)


--- branches/safari-612-branch/Source/WebCore/ChangeLog	2021-09-23 05:26:29 UTC (rev 282946)
+++ branches/safari-612-branch/Source/WebCore/ChangeLog	2021-09-23 05:34:12 UTC (rev 282947)
@@ -1,5 +1,44 @@
 2021-09-22  Alan Coon  <alanc...@apple.com>
 
+        Cherry-pick r282047. rdar://problem/83430148
+
+    Ensure fragmented flow state invalidation even when the cached fragmented flow is not present.
+    https://bugs.webkit.org/show_bug.cgi?id=229914
+    <rdar://82025006>
+    
+    Reviewed by Antti Koivisto.
+    
+    The cached fragmented flow is the byproduct of querying the enclosing fragment during layout/repaint.
+    Sometimes when the layout process, between 2 subsequent style change does not generate such cached fragmented flows
+    the invalidation process stops early and leaves subtrees in an inconsistent state.
+    
+    Let's use the passed in fragmented flow when the cached value is not present.
+    
+    * rendering/RenderBlock.cpp:
+    (WebCore::RenderBlock::resetEnclosingFragmentedFlowAndChildInfoIncludingDescendants):
+    
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@282047 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2021-09-05  Alan Bujtas  <za...@apple.com>
+
+            Ensure fragmented flow state invalidation even when the cached fragmented flow is not present.
+            https://bugs.webkit.org/show_bug.cgi?id=229914
+            <rdar://82025006>
+
+            Reviewed by Antti Koivisto.
+
+            The cached fragmented flow is the byproduct of querying the enclosing fragment during layout/repaint.
+            Sometimes when the layout process, between 2 subsequent style change does not generate such cached fragmented flows
+            the invalidation process stops early and leaves subtrees in an inconsistent state.
+
+            Let's use the passed in fragmented flow when the cached value is not present.
+
+            * rendering/RenderBlock.cpp:
+            (WebCore::RenderBlock::resetEnclosingFragmentedFlowAndChildInfoIncludingDescendants):
+
+2021-09-22  Alan Coon  <alanc...@apple.com>
+
         Cherry-pick r282774. rdar://problem/83429893
 
     [GPUP] Videos appear black but audio plays normally

Modified: branches/safari-612-branch/Source/WebCore/rendering/RenderBlock.cpp (282946 => 282947)


--- branches/safari-612-branch/Source/WebCore/rendering/RenderBlock.cpp	2021-09-23 05:26:29 UTC (rev 282946)
+++ branches/safari-612-branch/Source/WebCore/rendering/RenderBlock.cpp	2021-09-23 05:34:12 UTC (rev 282947)
@@ -2697,15 +2697,13 @@
     return rareData->m_enclosingFragmentedFlow.value().get();
 }
 
-void RenderBlock::resetEnclosingFragmentedFlowAndChildInfoIncludingDescendants(RenderFragmentedFlow*)
+void RenderBlock::resetEnclosingFragmentedFlowAndChildInfoIncludingDescendants(RenderFragmentedFlow* fragmentedFlow)
 {
     if (fragmentedFlowState() == NotInsideFragmentedFlow)
         return;
 
-    if (cachedEnclosingFragmentedFlowNeedsUpdate())
-        return;
-
-    auto* fragmentedFlow = cachedEnclosingFragmentedFlow();
+    if (auto* cachedFragmentedFlow = cachedEnclosingFragmentedFlow())
+        fragmentedFlow = cachedFragmentedFlow;
     setCachedEnclosingFragmentedFlowNeedsUpdate();
     RenderElement::resetEnclosingFragmentedFlowAndChildInfoIncludingDescendants(fragmentedFlow);
 }
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to