summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/i_oplmusic.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/i_oplmusic.c b/src/i_oplmusic.c
index 51a609d9..ab64505c 100644
--- a/src/i_oplmusic.c
+++ b/src/i_oplmusic.c
@@ -445,6 +445,13 @@ static void SetVoiceInstrument(opl_voice_t *voice, genmidi_instr_t *instr)
genmidi_voice_t *data;
unsigned int modulating;
+ // Instrument already set for this channel?
+
+ if (voice->current_instr == instr)
+ {
+ return;
+ }
+
voice->current_instr = instr;
data = &instr->opl2_voice;