From 113aa1e77fa82e9dc41c6f7cd30070457e995f33 Mon Sep 17 00:00:00 2001 From: Christopher Page Date: Mon, 7 Jul 2008 03:30:34 +0000 Subject: LURE: Made sure to lock _soundMutex in syncSounds() svn-id: r32934 --- engines/lure/sound.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'engines/lure/sound.cpp') diff --git a/engines/lure/sound.cpp b/engines/lure/sound.cpp index 94b7455a1f..d59d03f9c3 100644 --- a/engines/lure/sound.cpp +++ b/engines/lure/sound.cpp @@ -285,16 +285,17 @@ uint8 SoundManager::descIndexOf(uint8 soundNumber) { // Used to sync the volume for all channels with the Config Manager // void SoundManager::syncSounds(uint8 musicVol, uint8 sfxVol) { - MusicListIterator i; - musicInterface_TidySounds(); + g_system->lockMutex(_soundMutex); + MusicListIterator i; for (i = _playingSounds.begin(); i != _playingSounds.end(); ++i) { if ((*i)->isMusic()) (*i)->setVolume(musicVol); else (*i)->setVolume(sfxVol); } + g_system->unlockMutex(_soundMutex); } SoundDescResource *SoundManager::findSound(uint8 soundNumber) { -- cgit v1.2.3