Skip to content
Browse files
Handle a disconnected view during applyTopLeftLocationOffset

Reviewed by Alan Bujtas.

It appears that we can sometimes end up in a state where the document's
view is disconnected during didLayout, which calls applyTopleftLocationOffset.
This just adds a null check to handle this case for now.

* Source/WebCore/rendering/RenderBox.h:
(WebCore::RenderBox::applyTopLeftLocationOffset const):

Canonical link:
git-svn-id: 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
mattwoodrow committed Jun 8, 2022
1 parent 5e87c94 commit 6a16426d6de5e4e92d8a6e577763afc471a2be51
Showing 1 changed file with 1 addition and 1 deletion.
@@ -592,7 +592,7 @@ override;
void applyTopLeftLocationOffset(LayoutPoint& point) const
// This is inlined for speed, since it is used by updateLayerPosition() during scrolling.
if (!document().view()->hasFlippedBlockRenderers())
if (!document().view() || !document().view()->hasFlippedBlockRenderers())
point.move(m_frameRect.x(), m_frameRect.y());

0 comments on commit 6a16426

Please sign in to comment.