Bug 1126465 - Stop invoking On*NotDecoded when we didn't actually go through the promise. r=mattwoodrow

This isn't right, and it means that we can't assume at the top of
On{Audio,Video}{,Not}Decoded() that we're fresh out of promise dispatch, which
we want to do.
This commit is contained in:
Bobby Holley 2015-01-28 18:54:10 -08:00
parent cd041af404
commit 1ced738e43

View File

@ -156,7 +156,7 @@ MediaSourceReader::RequestAudioDataComplete(int64_t aTime)
void
MediaSourceReader::RequestAudioDataFailed(nsresult aResult)
{
OnAudioNotDecoded(DECODE_ERROR);
mAudioPromise.Reject(DECODE_ERROR, __func__);
}
void
@ -299,7 +299,7 @@ MediaSourceReader::RequestVideoDataComplete(int64_t aTime)
void
MediaSourceReader::RequestVideoDataFailed(nsresult aResult)
{
OnVideoNotDecoded(DECODE_ERROR);
mVideoPromise.Reject(DECODE_ERROR, __func__);
}
void