]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ALSA: seq: oss: Fix missing error check in snd_seq_oss_synth_make_info()
authorTakashi Iwai <tiwai@suse.de>
Fri, 15 Jan 2021 09:34:28 +0000 (10:34 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 30 Jan 2021 12:27:13 +0000 (13:27 +0100)
commit987cd6469b3729418ab31c503ca9ba243da1d6ea
tree7cba3a0a78fb6169d0857413b6a47f59a094b986
parent8db42574fc93d05e7f1f5fbd88af55f4f69ff586
ALSA: seq: oss: Fix missing error check in snd_seq_oss_synth_make_info()

commit 217bfbb8b0bfa24619b11ab75c135fec99b99b20 upstream.

snd_seq_oss_synth_make_info() didn't check the error code from
snd_seq_oss_midi_make_info(), and this leads to the call of strlcpy()
with the uninitialized string as the source, which may lead to the
access over the limit.

Add the proper error check for avoiding the failure.

Reported-by: syzbot+e42504ff21cff05a595f@syzkaller.appspotmail.com
Cc: <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20210115093428.15882-1-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
sound/core/seq/oss/seq_oss_synth.c