Index: Source/core/css/invalidation/StyleInvalidator.cpp |
diff --git a/Source/core/css/invalidation/StyleInvalidator.cpp b/Source/core/css/invalidation/StyleInvalidator.cpp |
index 38e3d91861617d01d19c53775a74397bdcaf8ea0..63541a4ec0f21f02ed40dca3d82ccf785c5241b1 100644 |
--- a/Source/core/css/invalidation/StyleInvalidator.cpp |
+++ b/Source/core/css/invalidation/StyleInvalidator.cpp |
@@ -177,7 +177,7 @@ bool StyleInvalidator::invalidate(Element& element, StyleInvalidator::RecursionD |
element.setNeedsStyleRecalc(LocalStyleChange, StyleChangeReasonForTracing::create(StyleChangeReason::StyleInvalidator)); |
} else if (recursionData.hasInvalidationSets() && someChildrenNeedStyleRecalc) { |
// Clone the LayoutStyle in order to preserve correct style sharing, if possible. Otherwise recalc style. |
- if (LayoutObject* renderer = element.renderer()) { |
+ if (LayoutObject* renderer = element.layoutObject()) { |
renderer->setStyleInternal(LayoutStyle::clone(renderer->styleRef())); |
} else { |
TRACE_STYLE_INVALIDATOR_INVALIDATION_IF_ENABLED(element, PreventStyleSharingForParent); |