aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
Diffstat (limited to 'sound')
-rw-r--r--sound/core/seq/oss/seq_oss_synth.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sound/core/seq/oss/seq_oss_synth.c b/sound/core/seq/oss/seq_oss_synth.c
index 558dadbf45f..e024e4588b8 100644
--- a/sound/core/seq/oss/seq_oss_synth.c
+++ b/sound/core/seq/oss/seq_oss_synth.c
@@ -604,6 +604,9 @@ snd_seq_oss_synth_make_info(struct seq_oss_devinfo *dp, int dev, struct synth_in
604{ 604{
605 struct seq_oss_synth *rec; 605 struct seq_oss_synth *rec;
606 606
607 if (dev < 0 || dev >= dp->max_synthdev)
608 return -ENXIO;
609
607 if (dp->synths[dev].is_midi) { 610 if (dp->synths[dev].is_midi) {
608 struct midi_info minf; 611 struct midi_info minf;
609 snd_seq_oss_midi_make_info(dp, dp->synths[dev].midi_mapped, &minf); 612 snd_seq_oss_midi_make_info(dp, dp->synths[dev].midi_mapped, &minf);