Bug 673806, unlink animation controller, r=dholbert
authorOlli Pettay <Olli.Pettay@helsinki.fi>
Mon, 25 Jul 2011 20:50:29 +0300
changeset 73296 504a1a927d39
parent 73295 58c04967ac5b
child 73325 982a5835fba1
child 73554 64b12627b7f4
child 104973 1c56144385ae
push id20845
push useropettay@mozilla.com
push date2011-07-25 18:14 +0000
treeherdermozilla-central@504a1a927d39 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdholbert
bugs673806
milestone8.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 673806, unlink animation controller, r=dholbert
content/base/src/nsDocument.cpp
--- a/content/base/src/nsDocument.cpp
+++ b/content/base/src/nsDocument.cpp
@@ -1951,16 +1951,22 @@ NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(ns
 
   tmp->mRadioGroups.Clear();
   
   // nsDocument has a pretty complex destructor, so we're going to
   // assume that *most* cycles you actually want to break somewhere
   // else, and not unlink an awful lot here.
 
   tmp->mIdentifierMap.Clear();
+
+#ifdef MOZ_SMIL
+  if (tmp->mAnimationController) {
+    tmp->mAnimationController->Unlink();
+  }
+#endif // MOZ_SMIL
   
   tmp->mInUnlinkOrDeletion = PR_FALSE;
 NS_IMPL_CYCLE_COLLECTION_UNLINK_END
 
 
 nsresult
 nsDocument::Init()
 {