Bug 1298217. Part 4 - Remove the call to DispatchDecodeTasksIfNeeded() from CheckIfDecodeComplete() because we've decoded all samples. draft
authorJW Wang <jwwang@mozilla.com>
Fri, 26 Aug 2016 06:08:54 +1200
changeset 406597 cb0362f9ec8946289e12ba8238d6ee0c884e0ef2
parent 406596 aefdc0ad3607a84effebc66c8865b559a471b924
child 406598 1402d7f069af0b835827563b6745af93ec9fe4df
push id27772
push userjwwang@mozilla.com
push dateMon, 29 Aug 2016 06:35:00 +0000
bugs1298217
milestone51.0a1
Bug 1298217. Part 4 - Remove the call to DispatchDecodeTasksIfNeeded() from CheckIfDecodeComplete() because we've decoded all samples. MozReview-Commit-ID: 22qa8K8j5zb
dom/media/MediaDecoderStateMachine.cpp
--- a/dom/media/MediaDecoderStateMachine.cpp
+++ b/dom/media/MediaDecoderStateMachine.cpp
@@ -830,17 +830,16 @@ MediaDecoderStateMachine::CheckIfDecodeC
   MOZ_ASSERT(OnTaskQueue());
   MOZ_ASSERT(mState == DECODER_STATE_DECODING ||
              mState == DECODER_STATE_BUFFERING);
 
   if (!IsVideoDecoding() && !IsAudioDecoding()) {
     // We've finished decoding all active streams,
     // so move to COMPLETED state.
     SetState(DECODER_STATE_COMPLETED);
-    DispatchDecodeTasksIfNeeded();
     ScheduleStateMachine();
   }
   DECODER_LOG("CheckIfDecodeComplete %scompleted",
               ((mState == DECODER_STATE_COMPLETED) ? "" : "NOT "));
 }
 
 bool MediaDecoderStateMachine::IsPlaying() const
 {