Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'fix/misc' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6

* 'fix/misc' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
ALSA: i2c/other/ak4xx-adda: Fix a compile warning with CONFIG_PROCFS=n
ALSA: prevent heap corruption in snd_ctl_new()

+6 -1
+5
sound/core/control.c
··· 31 31 32 32 /* max number of user-defined controls */ 33 33 #define MAX_USER_CONTROLS 32 34 + #define MAX_CONTROL_COUNT 1028 34 35 35 36 struct snd_kctl_ioctl { 36 37 struct list_head list; /* list of all ioctls */ ··· 196 195 197 196 if (snd_BUG_ON(!control || !control->count)) 198 197 return NULL; 198 + 199 + if (control->count > MAX_CONTROL_COUNT) 200 + return NULL; 201 + 199 202 kctl = kzalloc(sizeof(*kctl) + sizeof(struct snd_kcontrol_volatile) * control->count, GFP_KERNEL); 200 203 if (kctl == NULL) { 201 204 snd_printk(KERN_ERR "Cannot allocate control instance\n");
+1 -1
sound/i2c/other/ak4xxx-adda.c
··· 900 900 return 0; 901 901 } 902 902 #else /* !CONFIG_PROC_FS */ 903 - static int proc_init(struct snd_akm4xxx *ak) {} 903 + static int proc_init(struct snd_akm4xxx *ak) { return 0; } 904 904 #endif 905 905 906 906 int snd_akm4xxx_build_controls(struct snd_akm4xxx *ak)