SVG element may reference arbitrary DOM element before running its insertion logic
[WebKit-https.git] / Source / WebCore / svg / animation / SVGSMILElement.cpp
index 66a1b9e..275526b 100644 (file)
@@ -258,9 +258,12 @@ Node::InsertionNotificationRequest SVGSMILElement::insertedInto(ContainerNode& r
     if (m_timeContainer)
         m_timeContainer->notifyIntervalsChanged();
 
-    buildPendingResource();
+    return InsertionShouldCallDidNotifySubtreeInsertions;
+}
 
-    return InsertionDone;
+void SVGSMILElement::didNotifySubtreeInsertions(ContainerNode*)
+{
+    buildPendingResource();
 }
 
 void SVGSMILElement::removedFrom(ContainerNode& rootParent)