Bug 656804 - build broken with --enable-raw r=blassey a=gavin

This commit is contained in:
Michael Wu 2011-05-23 17:23:13 -07:00
parent 8dd395a2e1
commit 25810946a8

View File

@ -72,7 +72,7 @@ nsresult nsRawReader::ReadMetadata(nsVideoInfo* aInfo)
{
NS_ASSERTION(mDecoder->OnStateMachineThread(),
"Should be on state machine thread.");
mozilla::MonitorAutoEnter autoEnter(mMonitor);
mozilla::ReentrantMonitorAutoEnter autoEnter(mReentrantMonitor);
nsMediaStream* stream = mDecoder->GetCurrentStream();
NS_ASSERTION(stream, "Decoder has no media stream");
@ -126,8 +126,8 @@ nsresult nsRawReader::ReadMetadata(nsVideoInfo* aInfo)
PRInt64 length = stream->GetLength();
if (length != -1) {
mozilla::MonitorAutoExit autoExitMonitor(mMonitor);
mozilla::MonitorAutoEnter autoMonitor(mDecoder->GetMonitor());
mozilla::ReentrantMonitorAutoExit autoExitMonitor(mReentrantMonitor);
mozilla::ReentrantMonitorAutoEnter autoMonitor(mDecoder->GetReentrantMonitor());
mDecoder->GetStateMachine()->SetDuration(USECS_PER_S *
(length - sizeof(nsRawVideoHeader)) /
(mFrameSize * mFrameRate));
@ -171,7 +171,7 @@ PRBool nsRawReader::ReadFromStream(nsMediaStream *aStream, PRUint8* aBuf,
PRBool nsRawReader::DecodeVideoFrame(PRBool &aKeyframeSkip,
PRInt64 aTimeThreshold)
{
mozilla::MonitorAutoEnter autoEnter(mMonitor);
mozilla::ReentrantMonitorAutoEnter autoEnter(mReentrantMonitor);
NS_ASSERTION(mDecoder->OnStateMachineThread() || mDecoder->OnDecodeThread(),
"Should be on state machine thread or decode thread.");
@ -253,7 +253,7 @@ PRBool nsRawReader::DecodeVideoFrame(PRBool &aKeyframeSkip,
nsresult nsRawReader::Seek(PRInt64 aTime, PRInt64 aStartTime, PRInt64 aEndTime, PRInt64 aCurrentTime)
{
mozilla::MonitorAutoEnter autoEnter(mMonitor);
mozilla::ReentrantMonitorAutoEnter autoEnter(mReentrantMonitor);
NS_ASSERTION(mDecoder->OnStateMachineThread(),
"Should be on state machine thread.");
@ -284,8 +284,8 @@ nsresult nsRawReader::Seek(PRInt64 aTime, PRInt64 aStartTime, PRInt64 aEndTime,
}
{
mozilla::MonitorAutoExit autoMonitorExit(mMonitor);
mozilla::MonitorAutoEnter autoMonitor(mDecoder->GetMonitor());
mozilla::ReentrantMonitorAutoExit autoMonitorExit(mReentrantMonitor);
mozilla::ReentrantMonitorAutoEnter autoMonitor(mDecoder->GetReentrantMonitor());
if (mDecoder->GetDecodeState() ==
nsBuiltinDecoderStateMachine::DECODER_STATE_SHUTDOWN) {
mCurrentFrame = frame;