aboutsummaryrefslogtreecommitdiff
path: root/engines/sci
diff options
context:
space:
mode:
Diffstat (limited to 'engines/sci')
-rw-r--r--engines/sci/sound/drivers/adlib.cpp4
-rw-r--r--engines/sci/sound/drivers/cms.cpp2
-rw-r--r--engines/sci/sound/drivers/fb01.cpp2
3 files changed, 4 insertions, 4 deletions
diff --git a/engines/sci/sound/drivers/adlib.cpp b/engines/sci/sound/drivers/adlib.cpp
index 191e13db0a..3229fd7071 100644
--- a/engines/sci/sound/drivers/adlib.cpp
+++ b/engines/sci/sound/drivers/adlib.cpp
@@ -512,7 +512,7 @@ int MidiDriver_AdLib::findVoiceBasic(int channel) {
}
if (voice == -1) {
- if (oldestVoice != -1) {
+ if (oldestVoice >= 0) {
voiceOff(oldestVoice);
voice = oldestVoice;
} else {
@@ -550,7 +550,7 @@ int MidiDriver_AdLib::findVoice(int channel) {
}
if (voice == -1) {
- if (oldestVoice != -1) {
+ if (oldestVoice >= 0) {
voiceOff(oldestVoice);
voice = oldestVoice;
} else {
diff --git a/engines/sci/sound/drivers/cms.cpp b/engines/sci/sound/drivers/cms.cpp
index dbcbf3d431..fd60863177 100644
--- a/engines/sci/sound/drivers/cms.cpp
+++ b/engines/sci/sound/drivers/cms.cpp
@@ -422,7 +422,7 @@ int MidiDriver_CMS::findVoiceBasic(int channel) {
}
if (voice == -1) {
- if (oldestVoice != -1) {
+ if (oldestVoice >= 0) {
voiceOff(oldestVoice);
voice = oldestVoice;
} else {
diff --git a/engines/sci/sound/drivers/fb01.cpp b/engines/sci/sound/drivers/fb01.cpp
index 9f3945bbec..b16473e62e 100644
--- a/engines/sci/sound/drivers/fb01.cpp
+++ b/engines/sci/sound/drivers/fb01.cpp
@@ -250,7 +250,7 @@ int MidiPlayer_Fb01::findVoice(int channel) {
}
if (voice == -1) {
- if (oldestVoice != -1) {
+ if (oldestVoice >= 0) {
voiceOff(oldestVoice);
voice = oldestVoice;
} else {