Chromium Code Reviews| Index: Source/core/svg/SVGElement.cpp |
| diff --git a/Source/core/svg/SVGElement.cpp b/Source/core/svg/SVGElement.cpp |
| index fddac6d6e4d3eaa15604c38df356afb1eb3e51e1..a9eb2532d1ae9d5d287e25377482dcda196ba462 100644 |
| --- a/Source/core/svg/SVGElement.cpp |
| +++ b/Source/core/svg/SVGElement.cpp |
| @@ -175,10 +175,10 @@ bool SVGElement::rendererIsNeeded(const RenderStyle& style) |
| // Spec: SVG allows inclusion of elements from foreign namespaces anywhere |
| // with the SVG content. In general, the SVG user agent will include the unknown |
| // elements in the DOM but will otherwise ignore unknown elements. |
| - if (!parentOrShadowHostElement() || parentOrShadowHostElement()->isSVGElement()) |
| - return Element::rendererIsNeeded(style); |
| + if ((parentOrShadowHostElement() && !parentOrShadowHostElement()->isSVGElement()) || !isValid()) |
|
esprehn
2014/06/17 23:09:40
Put these in separate if statements.
if (parentOr
|
| + return false; |
| - return false; |
| + return Element::rendererIsNeeded(style); |
| } |
| SVGElementRareData* SVGElement::ensureSVGRareData() |