don't RageException::Throw from a thread

This commit is contained in:
Glenn Maynard
2007-05-03 02:10:26 +00:00
parent 11a5727d7e
commit c5448c61d5
2 changed files with 6 additions and 6 deletions
@@ -73,8 +73,8 @@ bool RageSoundDriver_WaveOut::GetData()
this->Mix( (int16_t *) m_aBuffers[b].lpData, chunksize_frames, m_iLastCursorPos, GetPosition() );
MMRESULT ret = waveOutWrite( m_hWaveOut, &m_aBuffers[b], sizeof(m_aBuffers[b]) );
if(ret != MMSYSERR_NOERROR)
RageException::Throw(wo_ssprintf(ret, "waveOutWrite failed"));
if( ret != MMSYSERR_NOERROR )
FAIL_M( wo_ssprintf(ret, "waveOutWrite failed") );
/* Increment m_iLastCursorPos. */
m_iLastCursorPos += chunksize_frames;
@@ -94,7 +94,7 @@ int64_t RageSoundDriver_WaveOut::GetPosition() const
tm.wType = TIME_SAMPLES;
MMRESULT ret = waveOutGetPosition( m_hWaveOut, &tm, sizeof(tm) );
if( ret != MMSYSERR_NOERROR )
RageException::Throw( wo_ssprintf(ret, "waveOutGetPosition failed") );
FAIL_M( wo_ssprintf(ret, "waveOutGetPosition failed") );
return tm.u.sample;
}