9 Apr 2006 17:09
[Patch] Dont call ac97_release_codec with NULL argument in oss/es1371.c
Eric Sesterhenn <snakebyte <at> gmx.de>
2006-04-09 15:09:16 GMT
2006-04-09 15:09:16 GMT
hi, this is a fix for coverity id #243. We only jump to err_codec if ac97_alloc_codec() fails its malloc() in which case codec is NULL. Since ac97_release_codec dereferences its argument we shouldnt call it with a NULL argument. Signed-off-by: Eric Sesterhenn <snakebyte <at> gmx.de> --- linux-2.6.17-rc1/sound/oss/es1371.c.orig 2006-04-09 17:03:22.000000000 +0200 +++ linux-2.6.17-rc1/sound/oss/es1371.c 2006-04-09 17:03:55.000000000 +0200 <at> <at> -3040,8 +3040,8 <at> <at> static int __devinit es1371_probe(struct err_irq: release_region(s->io, ES1371_EXTENT); err_region: - err_codec: ac97_release_codec(s->codec); + err_codec: kfree(s); return res; } - To unsubscribe from this list: send the line "unsubscribe linux-sound" in the body of a message to majordomo <at> vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
RSS Feed