Bug 1123198 - Run reset parser state algorithm when aborting. r=cajbir, a=sledru
authorJean-Yves Avenard <jyavenard@mozilla.com>
Thu, 22 Jan 2015 21:19:02 +1100
changeset 243018 17830430e6be
parent 243017 cb103a939041
child 243019 c1e9f11144a5
push id4364
push userryanvm@gmail.com
push date2015-01-24 16:33 +0000
treeherdermozilla-beta@34330baf2af6 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerscajbir, sledru
bugs1123198
milestone36.0
Bug 1123198 - Run reset parser state algorithm when aborting. r=cajbir, a=sledru
dom/media/mediasource/SourceBuffer.cpp
--- a/dom/media/mediasource/SourceBuffer.cpp
+++ b/dom/media/mediasource/SourceBuffer.cpp
@@ -164,17 +164,17 @@ SourceBuffer::Abort(ErrorResult& aRv)
   if (mMediaSource->ReadyState() != MediaSourceReadyState::Open) {
     aRv.Throw(NS_ERROR_DOM_INVALID_STATE_ERR);
     return;
   }
   if (mUpdating) {
     // TODO: Abort segment parser loop, buffer append, and stream append loop algorithms.
     AbortUpdating();
   }
-  // TODO: Run reset parser algorithm.
+  mTrackBuffer->ResetParserState();
   mAppendWindowStart = 0;
   mAppendWindowEnd = PositiveInfinity<double>();
 
   MSE_DEBUG("SourceBuffer(%p)::Abort() Discarding decoder", this);
   mTrackBuffer->DiscardDecoder();
 }
 
 void