summaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2013-02-17 14:33:04 +0100
committerTakashi Iwai <tiwai@suse.de>2013-02-17 18:02:00 +0100
commit4909a0caabb8b4352efcea223e58b86f8bc1f98b (patch)
treed1ab789fbca64ee1cd7e7f0deede7c6f855bd87d /sound
parentMerge tag 'asoc-3.9-updates' of git://git.kernel.org/pub/scm/linux/kernel/git... (diff)
downloadlinux-4909a0caabb8b4352efcea223e58b86f8bc1f98b.tar.xz
linux-4909a0caabb8b4352efcea223e58b86f8bc1f98b.zip
ALSA: usb/quirks, fix out-of-bounds access
bootresponse in snd_usb_mbox2_boot_quirk is only 12 (decimal) u8's long, but i9s passed to snd_usb_ctl_msg as it would be 0x12 (hexa) long. Fix that by having proper size of the array, i.e. 0x12. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound')
-rw-r--r--sound/usb/quirks.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/usb/quirks.c b/sound/usb/quirks.c
index 7d7ad0b0620e..5325a3869bb7 100644
--- a/sound/usb/quirks.c
+++ b/sound/usb/quirks.c
@@ -533,7 +533,7 @@ static int snd_usb_mbox2_boot_quirk(struct usb_device *dev)
{
struct usb_host_config *config = dev->actconfig;
int err;
- u8 bootresponse[12];
+ u8 bootresponse[0x12];
int fwsize;
int count;