Index: third_party/WebKit/Source/core/svg/SVGGElement.cpp |
diff --git a/third_party/WebKit/Source/core/svg/SVGGElement.cpp b/third_party/WebKit/Source/core/svg/SVGGElement.cpp |
index dbd19e438b419ce58a3be3130a7b329c713bc807..3198284ca099b9109146d58db4c00fe05b9b0d7c 100644 |
--- a/third_party/WebKit/Source/core/svg/SVGGElement.cpp |
+++ b/third_party/WebKit/Source/core/svg/SVGGElement.cpp |
@@ -49,7 +49,7 @@ bool SVGGElement::layoutObjectIsNeeded(const ComputedStyle&) { |
// even if display is set to 'none' - which is special to SVG <g> container |
// elements. |
return parentOrShadowHostElement() && |
- parentOrShadowHostElement()->isSVGElement(); |
+ parentOrShadowHostElement()->isSVGElement() && isValid(); |
} |
} // namespace blink |