Bug 1308147. Part 4 - reject mPendingSeek in WaitForCDMState::Exit().
MozReview-Commit-ID: H7ChCplXhBM
--- a/dom/media/MediaDecoderStateMachine.cpp
+++ b/dom/media/MediaDecoderStateMachine.cpp
@@ -376,18 +376,19 @@ public:
// where mQueuedSeek must be empty.
MOZ_ASSERT(!mMaster->mQueuedSeek.Exists());
mPendingDormant = aPendingDormant;
}
void Exit() override
{
- // Transfer the seek job so it is available to the next state.
- mMaster->mQueuedSeek = Move(mPendingSeek);
+ // mPendingSeek is either moved in HandleCDMProxyReady() or should be
+ // rejected here before transition to SHUTDOWN.
+ mPendingSeek.RejectIfExists(__func__);
}
State GetState() const override
{
return DECODER_STATE_WAIT_FOR_CDM;
}
bool HandleDormant(bool aDormant) override;