Bug 1043111 - Allow |mState==DECODER_STATE_DORMANT| in MediaDecoderStateMachine::ResetPlayback(). r=kinetik
authorJW Wang <jwwang@mozilla.com>
Wed, 23 Jul 2014 20:29:00 +0200
changeset 217458 b97c05712090e560fc280fb3c0cd5a5b0e26c51e
parent 217457 d13295f54df11fbaf5883e6a41c0cad57843f508
child 217459 e6828c19a0e453a821555b85a265d4d951ebc383
push id3979
push userraliiev@mozilla.com
push dateMon, 13 Oct 2014 16:35:44 +0000
treeherdermozilla-beta@30f2cc610691 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskinetik
bugs1043111
milestone34.0a1
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
Bug 1043111 - Allow |mState==DECODER_STATE_DORMANT| in MediaDecoderStateMachine::ResetPlayback(). r=kinetik
content/media/MediaDecoderStateMachine.cpp
--- a/content/media/MediaDecoderStateMachine.cpp
+++ b/content/media/MediaDecoderStateMachine.cpp
@@ -1400,17 +1400,19 @@ void MediaDecoderStateMachine::Play()
   // Once we start playing, we don't want to minimize our prerolling, as we
   // assume the user is likely to want to keep playing in future.
   mMinimizePreroll = false;
   ScheduleStateMachine();
 }
 
 void MediaDecoderStateMachine::ResetPlayback()
 {
-  MOZ_ASSERT(mState == DECODER_STATE_SEEKING || mState == DECODER_STATE_SHUTDOWN);
+  MOZ_ASSERT(mState == DECODER_STATE_SEEKING ||
+             mState == DECODER_STATE_SHUTDOWN ||
+             mState == DECODER_STATE_DORMANT);
   mVideoFrameEndTime = -1;
   mAudioStartTime = -1;
   mAudioEndTime = -1;
   mAudioCompleted = false;
   AudioQueue().Reset();
   VideoQueue().Reset();
   mFirstVideoFrameAfterSeek = nullptr;
   mDropAudioUntilNextDiscontinuity = true;