aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/util/c++/clang.cpp
diff options
context:
space:
mode:
authorTakashi Iwai <[email protected]>2020-06-24 14:23:40 +0200
committerTakashi Iwai <[email protected]>2020-06-24 14:24:29 +0200
commit220345e98f1cdc768eeb6e3364a0fa7ab9647fe7 (patch)
treec3fd3927a037edc80b7ec782cd15e390089168fd /tools/perf/util/c++/clang.cpp
parenta32a1fc99807244d920d274adc46ba04b538cc8a (diff)
ALSA: usb-audio: Fix OOB access of mixer element list
The USB-audio mixer code holds a linked list of usb_mixer_elem_list, and several operations are performed for each mixer element. A few of them (snd_usb_mixer_notify_id() and snd_usb_mixer_interrupt_v2()) assume each mixer element being a usb_mixer_elem_info object that is a subclass of usb_mixer_elem_list, cast via container_of() and access it members. This may result in an out-of-bound access when a non-standard list element has been added, as spotted by syzkaller recently. This patch adds a new field, is_std_info, in usb_mixer_elem_list to indicate that the element is the usb_mixer_elem_info type or not, and skip the access to such an element if needed. Reported-by: [email protected] Reported-by: [email protected] Cc: <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Takashi Iwai <[email protected]>
Diffstat (limited to 'tools/perf/util/c++/clang.cpp')
0 files changed, 0 insertions, 0 deletions