From owner-freebsd-net@FreeBSD.ORG Wed Mar 8 11:29:34 2006 Return-Path: X-Original-To: net@FreeBSD.org Delivered-To: freebsd-net@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CED8A16A420; Wed, 8 Mar 2006 11:29:34 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailout1.pacific.net.au (mailout1.pacific.net.au [61.8.0.84]) by mx1.FreeBSD.org (Postfix) with ESMTP id 598DE43D45; Wed, 8 Mar 2006 11:29:34 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailproxy1.pacific.net.au (mailproxy1.pacific.net.au [61.8.0.86]) by mailout1.pacific.net.au (Postfix) with ESMTP id 9864A337CDE; Wed, 8 Mar 2006 22:29:32 +1100 (EST) Received: from katana.zip.com.au (katana.zip.com.au [61.8.7.246]) by mailproxy1.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id k28BTR15004343; Wed, 8 Mar 2006 22:29:28 +1100 Date: Wed, 8 Mar 2006 22:29:27 +1100 (EST) From: Bruce Evans X-X-Sender: bde@delplex.bde.org To: Kris Kennaway In-Reply-To: <20060306231556.GA54600@xor.obsecurity.org> Message-ID: <20060308222124.O20893@delplex.bde.org> References: <20050927222721.GA46411@xor.obsecurity.org> <20051001214002.GU45345@cell.sick.ru> <20051005173837.GA36638@xor.obsecurity.org> <20051005174012.GB36638@xor.obsecurity.org> <20060306231556.GA54600@xor.obsecurity.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: gnn@FreeBSD.org, Hajimu UMEMOTO , net@FreeBSD.org Subject: Re: ipv6 panic in 6.0 ([kris@FreeBSD.org: kern/85780: 'panic: bogus refcnt 0' in routing/ipv6]) X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Mar 2006 11:29:34 -0000 On Mon, 6 Mar 2006, Kris Kennaway wrote: > P.S. This comment in netinet6/ip6_output.c appears to be bogus, since > RTFREE is only a single statement: > > if (ro == &ip6route && ro->ro_rt) { /* brace necessary for RTFREE */ > RTFREE(ro->ro_rt); > } else if (ro_pmtu == &ip6route && ro_pmtu->ro_rt) { > RTFREE(ro_pmtu->ro_rt); > } This is because peter fixed RTFREE() 7 years ago in rev.1.29 of route.h. It used not to be wrapped in "do while (0)". It was also fixed in NetBSD 7.5 years ago so there should be few portabilty problems with assuming that it is fixed. NetBSD is missing the style bug in rev.1.29 (indentation of the wrapped code instead of outdentation of the do-while). Bruce