linux/sound/pci/asihpi
Jesper Juhl fd0977d0f4 ALSA: asihpi - Unsafe memory management when allocating control cache
I noticed that sound/pci/asihpi/hpicmn.c::hpi_alloc_control_cache() does
not check the return value from kmalloc(), which may fail.
If kmalloc() fails we'll dereference a null pointer and things will go bad
fast.
There are two memory allocations in that function and there's also the
problem that the first may succeed and the second may fail and nothing is
done about that either which will also go wrong down the line.

Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Acked-by: Eliot Blennerhassett <linux@audioscience.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-11-02 07:38:21 +01:00
..
Makefile
asihpi.c ALSA: asihpi: fix sign bug 2010-07-16 08:30:08 +02:00
hpi.h ALSA: asihpi - HPI version 4.04.01 2010-07-16 11:31:37 +02:00
hpi6000.c ALSA: asihpi - Unsafe memory management when allocating control cache 2010-11-02 07:38:21 +01:00
hpi6000.h
hpi6205.c ALSA: asihpi - Unsafe memory management when allocating control cache 2010-11-02 07:38:21 +01:00
hpi6205.h
hpi_internal.h ALSA: asihpi - Avoid using c99 uintX types. 2010-07-16 11:33:47 +02:00
hpicmn.c ALSA: asihpi - Unsafe memory management when allocating control cache 2010-11-02 07:38:21 +01:00
hpicmn.h
hpidebug.c ALSA: asihpi - Remove unneeded ; 2010-07-06 08:20:43 +02:00
hpidebug.h ALSA: asihpi - HPI API updates 2010-07-06 08:18:27 +02:00
hpidspcd.c
hpidspcd.h
hpifunc.c ALSA: asihpi - Avoid useless assignment of returned index values. 2010-07-16 11:34:23 +02:00
hpimsginit.c
hpimsginit.h
hpimsgx.c ALSA: hpimsgx: fix wrong sizeof 2010-07-28 11:53:03 +02:00
hpimsgx.h
hpioctl.c ALSA: asihpi: check return value of get_user() 2010-07-29 12:26:28 +02:00
hpioctl.h
hpios.c ALSA: asihpi - Remove unused io map functions 2010-05-27 09:50:47 +02:00
hpios.h ALSA: asihpi - Remove unused io map functions 2010-05-27 09:50:47 +02:00
hpipcida.h