NetBSD Problem Report #19037
Received: (qmail 28752 invoked by uid 605); 13 Nov 2002 16:54:36 -0000
Message-Id: <20021113165434.A6B8411124@narn.netbsd.org>
Date: Wed, 13 Nov 2002 08:54:34 -0800 (PST)
From: seanb@qnx.com
Sender: gnats-bugs-owner@netbsd.org
Reply-To: seanb@qnx.com
To: gnats-bugs@gnats.netbsd.org
Subject: Memory type mismatch in ether_ifdetach()
X-Send-Pr-Version: www-1.0
>Number: 19037
>Category: kern
>Synopsis: Memory type mismatch in ether_ifdetach()
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: kern-bug-people
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Nov 13 16:55:00 +0000 2002
>Closed-Date: Sun Jan 12 12:26:53 +0000 2003
>Last-Modified: Sun Jan 12 12:27:00 +0000 2003
>Originator: Sean Boudreau
>Release: 1-5
>Organization:
QNX
>Environment:
NetBSD fili 1.5.1 NetBSD 1.5.1 (ker.xtang) #2: Mon Jul 30 09:33:07 EDT 2001 root@fili:/usr/src/sys/arch/i386/compile/ker.xtang i386
>Description:
Ethernet multicast entries are malloc'd M_IFMADDR; however,
ether_ifdetach() free's M_IFADDR.
>How-To-Repeat:
>Fix:
Index: net/if_ethersubr.c
================================================================
RCS file: /cvsroot/syssrc/sys/net/if_ethersubr.c,v
retrieving revision 1.99
diff -c -r1.99 if_ethersubr.c
*** net/if_ethersubr.c 2002/09/11 05:36:26 1.99
--- net/if_ethersubr.c 2002/11/13 16:53:51
***************
*** 1092,1098 ****
s = splnet();
while ((enm = LIST_FIRST(&ec->ec_multiaddrs)) != NULL) {
LIST_REMOVE(enm, enm_list);
! free(enm, M_IFADDR);
ec->ec_multicnt--;
}
splx(s);
--- 1092,1098 ----
s = splnet();
while ((enm = LIST_FIRST(&ec->ec_multiaddrs)) != NULL) {
LIST_REMOVE(enm, enm_list);
! free(enm, M_IFMADDR);
ec->ec_multicnt--;
}
splx(s);
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed
State-Changed-By: jdolecek
State-Changed-When: Sun Jan 12 04:26:34 PST 2003
State-Changed-Why:
Supplied fix committed. Thank you.
From: Jaromir Dolecek <jdolecek@netbsd.org>
To: gnats-bugs@gnats.netbsd.org
Cc:
Subject: pr/19037 CVS commit: src/sys/net
Date: Sun, 12 Jan 2003 14:26:25 +0200 (EET)
Module Name: src
Committed By: jdolecek
Date: Sun Jan 12 12:26:24 UTC 2003
Modified Files:
src/sys/net: if_ethersubr.c
Log Message:
Ethernet multicast entries are malloc'd M_IFMADDR, and thus should
be freed as M_IFMADDR too.
Fix supplied in PR kern/19037 by Sean Boudreau
To generate a diff of this commit:
cvs rdiff -r1.99 -r1.100 src/sys/net/if_ethersubr.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.