Bug 1319992: P5. Don't attempt to estimate readyState when ended. r=jwwang

Buffered range is now calculated asynchronously. It may not be up to date by the time the MDSM has entered ended mode.
There's no point estimating readyState in ended mode anyway: we know what it is...

MozReview-Commit-ID: ErGsAwBzeXI
This commit is contained in:
Jean-Yves Avenard
2016-12-14 17:35:36 +11:00
parent 3365f04e35
commit 0ad1eadd95

View File

@@ -5474,7 +5474,7 @@ HTMLMediaElement::UpdateReadyStateInternal()
// 6. Suspend playback.
// Note: Playback will already be stalled, as the next frame is
// unavailable.
} else if (mDecoder) {
} else if (mDecoder && !mDecoder->IsEnded()) {
nextFrameStatus = mDecoder->NextFrameBufferedStatus();
}
}