From owner-freebsd-net@FreeBSD.ORG Wed Sep 10 12:23:43 2008 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0183B1065670 for ; Wed, 10 Sep 2008 12:23:43 +0000 (UTC) (envelope-from bms@FreeBSD.org) Received: from out3.smtp.messagingengine.com (out3.smtp.messagingengine.com [66.111.4.27]) by mx1.freebsd.org (Postfix) with ESMTP id C7F508FC08 for ; Wed, 10 Sep 2008 12:23:42 +0000 (UTC) (envelope-from bms@FreeBSD.org) Received: from compute1.internal (compute1.internal [10.202.2.41]) by out1.messagingengine.com (Postfix) with ESMTP id 65A94160A9E; Wed, 10 Sep 2008 08:23:42 -0400 (EDT) Received: from heartbeat2.messagingengine.com ([10.202.2.161]) by compute1.internal (MEProxy); Wed, 10 Sep 2008 08:23:42 -0400 X-Sasl-enc: mkn7AAyE5V6y4zCWNpAqLdzv0jxuEQJki+Sklkc40Wm4 1221049422 Received: from empiric.lon.incunabulum.net (82-35-112-254.cable.ubr07.dals.blueyonder.co.uk [82.35.112.254]) by mail.messagingengine.com (Postfix) with ESMTPSA id EAB8931D5F; Wed, 10 Sep 2008 08:23:41 -0400 (EDT) Message-ID: <48C7BC4C.4090106@FreeBSD.org> Date: Wed, 10 Sep 2008 13:23:40 +0100 From: "Bruce M. Simpson" User-Agent: Thunderbird 2.0.0.14 (X11/20080514) MIME-Version: 1.0 To: Brooks Davis References: <48C70743.1020003@incunabulum.net> <48C7112D.3070309@FreeBSD.org> <20080910003637.GB34060@lor.one-eyed-alien.net> In-Reply-To: <20080910003637.GB34060@lor.one-eyed-alien.net> X-Enigmail-Version: 0.95.6 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: FreeBSD-Net mailing list Subject: Re: Problem with IFDATA_DRIVERNAME sysctl 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, 10 Sep 2008 12:23:43 -0000 Brooks Davis wrote: > >> --- if_mib.c.orig 2008-09-10 00:31:25.000000000 +0100 >> +++ if_mib.c 2008-09-10 00:32:15.000000000 +0100 >> @@ -90,6 +90,7 @@ >> switch(name[1]) { >> default: >> return ENOENT; >> + break; >> > > That's clearly a no-op since it's unreachable. > > >> case IFDATA_GENERAL: >> bzero(&ifmd, sizeof(ifmd)); >> @@ -136,6 +137,7 @@ >> error = SYSCTL_IN(req, ifp->if_linkmib, ifp->if_linkmiblen); >> if (error) >> return error; >> + break; >> > > This looks OK, but I haven't checked the context. > It looks like an unintentional fall-through to case IFDATA_DRIVERNAME, so I'll commit that part.