aboutsummaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
Diffstat (limited to 'sound')
-rw-r--r--sound/mididrv.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/sound/mididrv.cpp b/sound/mididrv.cpp
index d164864fc2..aaff78bf92 100644
--- a/sound/mididrv.cpp
+++ b/sound/mididrv.cpp
@@ -228,6 +228,9 @@ MidiDriver::DeviceHandle MidiDriver::detectDevice(int flags) {
tp = MT_ADLIB;
else if (flags & MDT_PCSPK)
tp = MT_PCSPK;
+ else if (l == 0)
+ // if we haven't tried to find a MIDI device yet we do this now.
+ continue;
else
tp = MT_AUTO;