Index: third_party/WebKit/Source/core/svg/SVGStyleElement.cpp |
diff --git a/third_party/WebKit/Source/core/svg/SVGStyleElement.cpp b/third_party/WebKit/Source/core/svg/SVGStyleElement.cpp |
index e7a2086a1bc61a16875f51fbd2852b24bd48f84f..8a9ad0bd8e984b609a37ae5185b864c4f3900c5b 100644 |
--- a/third_party/WebKit/Source/core/svg/SVGStyleElement.cpp |
+++ b/third_party/WebKit/Source/core/svg/SVGStyleElement.cpp |
@@ -100,7 +100,7 @@ void SVGStyleElement::setTitle(const AtomicString& title) |
void SVGStyleElement::parseAttribute(const QualifiedName& name, const AtomicString& oldValue, const AtomicString& value) |
{ |
if (name == SVGNames::titleAttr) { |
- if (m_sheet) |
+ if (m_sheet && isInDocumentTree()) |
m_sheet->setTitle(value); |
return; |