Bug 988760 - Account extra time since blocking correctly. r=karlt, a=1.3+
authorGabriele Svelto <gsvelto@mozilla.com>
Mon, 07 Apr 2014 13:20:57 +0200
changeset 193035 0de33d74936a85aca1163e3147c6b03fdb1e93a4
parent 193034 d42f2a9973d71cdbad89b2a6554ad88b1da411d1
child 193036 b7feb91cf1d843a359bb8513cc6fe7a8162bf8b7
push id474
push userasasaki@mozilla.com
push dateMon, 02 Jun 2014 21:01:02 +0000
treeherdermozilla-release@967f4cf1b31c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskarlt, 1
bugs988760
milestone30.0a2
Bug 988760 - Account extra time since blocking correctly. r=karlt, a=1.3+
content/media/webaudio/AudioDestinationNode.cpp
--- a/content/media/webaudio/AudioDestinationNode.cpp
+++ b/content/media/webaudio/AudioDestinationNode.cpp
@@ -563,24 +563,24 @@ AudioDestinationNode::SetIsOnlyNodeForCo
     // show up in its result buffer. Also, we would get confused by adding
     // ExtraCurrentTime before StartRendering has even been called.
     return;
   }
 
   if (aIsOnlyNode) {
     mStream->ChangeExplicitBlockerCount(1);
     mStartedBlockingDueToBeingOnlyNode = TimeStamp::Now();
-    mExtraCurrentTimeSinceLastStartedBlocking = 0;
     // Don't do an update of mExtraCurrentTimeSinceLastStartedBlocking until the next stable state.
     mExtraCurrentTimeUpdatedSinceLastStableState = true;
     ScheduleStableStateNotification();
   } else {
     // Force update of mExtraCurrentTimeSinceLastStartedBlocking if necessary
     ExtraCurrentTime();
     mExtraCurrentTime += mExtraCurrentTimeSinceLastStartedBlocking;
+    mExtraCurrentTimeSinceLastStartedBlocking = 0;
     mStream->ChangeExplicitBlockerCount(-1);
     mStartedBlockingDueToBeingOnlyNode = TimeStamp();
   }
 }
 
 }
 
 }