Backed out changeset c864d8ec3ba3 (bug 1208373)
authorCarsten "Tomcat" Book <cbook@mozilla.com>
Thu, 09 Jun 2016 15:18:40 +0200
changeset 301289 4ba996f363fe3efd564bb6415603a0d72851b9b0
parent 301288 144cbe0bd3e3cc40cbb3ae99924e1a99abbbf36e
child 301290 9177f45a2521bc10a84e7cd17416c712f6b77eee
push id78275
push usercbook@mozilla.com
push dateThu, 09 Jun 2016 13:19:23 +0000
treeherdermozilla-inbound@df403befe9fe [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1208373
milestone50.0a1
backs outc864d8ec3ba36ead778d798f14b2107a53a6d290
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
Backed out changeset c864d8ec3ba3 (bug 1208373)
dom/media/StreamTracks.cpp
--- a/dom/media/StreamTracks.cpp
+++ b/dom/media/StreamTracks.cpp
@@ -98,14 +98,20 @@ StreamTracks::ForgetUpTo(StreamTime aTim
   const StreamTime minChunkSize = 2400;
   if (aTime < mForgottenTime + minChunkSize) {
     return;
   }
   mForgottenTime = aTime;
 
   for (uint32_t i = 0; i < mTracks.Length(); ++i) {
     Track* track = mTracks[i];
+    if (track->IsEnded() && track->GetEnd() <= aTime) {
+      mTracks.RemoveElementAt(i);
+      mTracksDirty = true;
+      --i;
+      continue;
+    }
     StreamTime forgetTo = std::min(track->GetEnd() - 1, aTime);
     track->ForgetUpTo(forgetTo);
   }
 }
 
 } // namespace mozilla