Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/ic fix memory leak, found by Brainy.
details: https://anonhg.NetBSD.org/src/rev/5274de02d779
branches: trunk
changeset: 337152:5274de02d779
user: christos <christos%NetBSD.org@localhost>
date: Sat Apr 04 15:09:45 2015 +0000
description:
fix memory leak, found by Brainy.
XXX: is there anything else that we need to cleanup at this point?
diffstat:
sys/dev/ic/ac97.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diffs (26 lines):
diff -r 5526ac0d28a7 -r 5274de02d779 sys/dev/ic/ac97.c
--- a/sys/dev/ic/ac97.c Sat Apr 04 15:08:40 2015 +0000
+++ b/sys/dev/ic/ac97.c Sat Apr 04 15:09:45 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ac97.c,v 1.95 2012/10/27 17:18:18 chs Exp $ */
+/* $NetBSD: ac97.c,v 1.96 2015/04/04 15:09:45 christos Exp $ */
/* $OpenBSD: ac97.c,v 1.8 2000/07/19 09:01:35 csapuntz Exp $ */
/*
@@ -63,7 +63,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ac97.c,v 1.95 2012/10/27 17:18:18 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ac97.c,v 1.96 2015/04/04 15:09:45 christos Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -1444,6 +1444,7 @@
if (as->ext_mid == 0 || as->ext_mid == 0xffff) {
aprint_normal_dev(sc_dev, "no modem codec found\n");
+ free(as, M_DEVBUF);
return ENXIO;
}
as->type = AC97_CODEC_TYPE_MODEM;
Home |
Main Index |
Thread Index |
Old Index