diff options
author | Paweł Kołodziejski | 2002-10-15 18:08:20 +0000 |
---|---|---|
committer | Paweł Kołodziejski | 2002-10-15 18:08:20 +0000 |
commit | 15ac1c1ee9292073fb8dead67111e31c8f328690 (patch) | |
tree | ee37dac21f50a5bad2f308ec0607472f24edecf9 /sound/mixer.cpp | |
parent | 53c60b20d895f9a35de742334317cd4ff1ed4133 (diff) | |
download | scummvm-rg350-15ac1c1ee9292073fb8dead67111e31c8f328690.tar.gz scummvm-rg350-15ac1c1ee9292073fb8dead67111e31c8f328690.tar.bz2 scummvm-rg350-15ac1c1ee9292073fb8dead67111e31c8f328690.zip |
fix
svn-id: r5156
Diffstat (limited to 'sound/mixer.cpp')
-rw-r--r-- | sound/mixer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/mixer.cpp b/sound/mixer.cpp index 931f8c05aa..e13f6c601b 100644 --- a/sound/mixer.cpp +++ b/sound/mixer.cpp @@ -112,12 +112,12 @@ int SoundMixer::playStream(PlayingSoundHandle * handle, int idx, void * sound, u } void SoundMixer::stopChannel(int index) { - if (index < 0) { + if ((index < 0) || (index >= NUM_CHANNELS)) { warning("soundMixer::stopChannel has invalid index %d", index); return; } - if (_channels[index] == NULL) { + if (_channels[index] != NULL) { _channels[index]->_toBeDestroyed = true; } } |