- fixed: When playing non-looping songs GMESong::Read could return without releasing the critical section.

SVN r2988 (trunk)
This commit is contained in:
Christoph Oelckers 2010-11-07 14:25:08 +00:00
parent b771426ea2
commit dff4553663
2 changed files with 1 additions and 2 deletions

View File

@ -477,8 +477,6 @@ MusInfo *I_RegisterSong (const char *filename, BYTE *musiccache, int offset, int
EMIDIType miditype = IdentifyMIDIType(id, sizeof(id)); EMIDIType miditype = IdentifyMIDIType(id, sizeof(id));
if (miditype != MIDI_NOTMIDI) if (miditype != MIDI_NOTMIDI)
{ {
TArray<BYTE> midi;
EMidiDevice devtype = (EMidiDevice)device; EMidiDevice devtype = (EMidiDevice)device;
retry_as_fmod: retry_as_fmod:

View File

@ -349,6 +349,7 @@ bool GMESong::Read(SoundStream *stream, void *buff, int len, void *userdata)
else else
{ {
memset(buff, 0, len); memset(buff, 0, len);
song->CritSec.Leave();
return false; return false;
} }
} }