Bug 1323847: [MSE] P2. Don't evict sample containing currentTime. r=gerald. a=gchang
authorJean-Yves Avenard <jyavenard@mozilla.com>
Fri, 16 Dec 2016 16:05:21 +1100
changeset 353148 432f1e56a9d72ac1708c4b58e69fff969e4441ed
parent 353147 5e31406f2b198839adb6243246b6a1681eae8ec8
child 353149 2e98fec3a9f925a3f313e9d1a20dd03bcc7526ce
push id6795
push userjlund@mozilla.com
push dateMon, 23 Jan 2017 14:19:46 +0000
treeherdermozilla-esr52@76101b503191 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgerald, gchang
bugs1323847
milestone52.0a2
Bug 1323847: [MSE] P2. Don't evict sample containing currentTime. r=gerald. a=gchang MozReview-Commit-ID: KjX10EPzUJN
dom/media/mediasource/TrackBuffersManager.cpp
--- a/dom/media/mediasource/TrackBuffersManager.cpp
+++ b/dom/media/mediasource/TrackBuffersManager.cpp
@@ -441,17 +441,17 @@ TrackBuffersManager::DoEvictData(const T
     if (frame->mKeyframe) {
       lastKeyFrameIndex = i;
       toEvict -= partialEvict;
       if (toEvict < 0) {
         break;
       }
       partialEvict = 0;
     }
-    if (frame->mTime >= lowerLimit.ToMicroseconds()) {
+    if (frame->GetEndTime() >= lowerLimit.ToMicroseconds()) {
       break;
     }
     partialEvict += frame->ComputedSizeOfIncludingThis();
   }
 
   const int64_t finalSize = mSizeSourceBuffer - aSizeToEvict;
 
   if (lastKeyFrameIndex > 0) {