From owner-cvs-src Fri Mar 21 7:47:26 2003 Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CB88E37B401; Fri, 21 Mar 2003 07:47:24 -0800 (PST) Received: from sasami.jurai.net (sasami.jurai.net [66.92.160.223]) by mx1.FreeBSD.org (Postfix) with ESMTP id CFBAB43F93; Fri, 21 Mar 2003 07:47:23 -0800 (PST) (envelope-from mdodd@FreeBSD.ORG) Received: from sasami.jurai.net (sasami.jurai.net [66.92.160.223]) by sasami.jurai.net (8.12.8/8.12.8) with ESMTP id h2LFlNCi077034; Fri, 21 Mar 2003 10:47:23 -0500 (EST) (envelope-from mdodd@FreeBSD.ORG) Date: Fri, 21 Mar 2003 10:47:23 -0500 (EST) From: "Matthew N. Dodd" X-X-Sender: winter@sasami.jurai.net To: src-committers@FreeBSD.ORG, cvs-src@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/sys/net bpf.c In-Reply-To: <200303211513.h2LFDTqQ069691@repoman.freebsd.org> Message-ID: <20030321104447.C8716@sasami.jurai.net> References: <200303211513.h2LFDTqQ069691@repoman.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-cvs-src@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 21 Mar 2003, Matthew N. Dodd wrote: > mdodd 2003/03/21 07:13:29 PST > > FreeBSD src repository > > Modified files: > sys/net bpf.c > Log: > Assignment could be NULL, check. [I've been informed that this is a little terse.] A struct pointer is assigned as a result of list iteration that could terminate without a match causing it to be NULL. A conditional test referencing it will blow up. This happened when bpf_detach() is called on an interface that was not treated to bpf_attach(). -- | Matthew N. Dodd | '78 Datsun 280Z | '75 Volvo 164E | FreeBSD/NetBSD | | winter@jurai.net | 2 x '84 Volvo 245DL | ix86,sparc,pmax | | http://www.jurai.net/~winter | For Great Justice! | ISO8802.5 4ever | To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-src" in the body of the message