Fix for bug 413281 (Firefox leaks when Yahoo Toolbar is installed). r=stuart, sr=sicking.
authorpeterv@propagandism.org
Thu, 24 Jan 2008 07:18:14 -0800
changeset 10626 74df64bd2f94492c19ff9c4be39b06c39cac615c
parent 10625 b8bc035603f32b1d3571a3d7bbb1c50e75f3947e
child 10627 bfe134e3e27496961dbe317bcdeead9460601c1d
push id1
push userbsmedberg@mozilla.com
push dateThu, 20 Mar 2008 16:49:24 +0000
treeherdermozilla-central@61007906a1f8 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersstuart, sicking
bugs413281
milestone1.9b3pre
Fix for bug 413281 (Firefox leaks when Yahoo Toolbar is installed). r=stuart, sr=sicking.
xpcom/threads/TimerThread.cpp
--- a/xpcom/threads/TimerThread.cpp
+++ b/xpcom/threads/TimerThread.cpp
@@ -161,16 +161,17 @@ nsresult TimerThread::Shutdown()
 
     // notify the cond var so that Run() can return
     if (mCondVar && mWaiting)
       PR_NotifyCondVar(mCondVar);
 
     nsTimerImpl *timer;
     for (PRInt32 i = mTimers.Count() - 1; i >= 0; i--) {
       timer = static_cast<nsTimerImpl*>(mTimers[i]);
+      timer->ReleaseCallback();
       RemoveTimerInternal(timer);
     }
   }
 
   mThread->Shutdown();    // wait for the thread to die
 
   PR_LOG(gTimerLog, PR_LOG_DEBUG, ("TimerThread::Shutdown end\n"));
   return NS_OK;