sound/isa/ad1816a/ad1816a.c: check kmalloc()
Subsystems (2)
PATCH 1/1 sound/isa/ad1816a/ad1816a.c: check kmalloc()
Description: Check the return value of kmalloc() in function snd_card_ad1816a_pnp(), in file sound/isa/ad1816a/ad1816a.c.
Signed-off-by Amit Choudhary <[email protected]>
sound/isa/ad1816a/ad1816a.c +2 -0
@@ -120,6 +120,8 @@ static int __devinit snd_card_ad1816a_pnstruct pnp_resource_table *cfg =kmalloc (sizeof (*cfg),GFP_KERNEL );int err; +if (!cfg) +return -ENOMEM ; acard->dev =pnp_request_card_device (card, id->devs[0 ].id,NULL );if (acard->dev =NULL ) {kfree (cfg);
_______________________________________________
Kernel-janitors mailing list
[email protected]
https://lists.osdl.org/mailman/listinfo/kernel-janitors