From owner-freebsd-stable@FreeBSD.ORG Wed Jan 2 16:20:29 2008 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C78B216A417 for ; Wed, 2 Jan 2008 16:20:29 +0000 (UTC) (envelope-from krassi@bulinfo.net) Received: from mx.bulinfo.net (mx.bulinfo.net [193.194.156.1]) by mx1.freebsd.org (Postfix) with ESMTP id 8241F13C465 for ; Wed, 2 Jan 2008 16:20:29 +0000 (UTC) (envelope-from krassi@bulinfo.net) Received: from localhost (localhost [127.0.0.1]) by mx.bulinfo.net (Postfix) with ESMTP id 71F9415819; Wed, 2 Jan 2008 18:20:28 +0200 (EET) Received: from mx.bulinfo.net ([127.0.0.1]) by localhost (mx.bulinfo.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 18014-08; Wed, 2 Jan 2008 18:20:26 +0200 (EET) Received: from [192.168.2.188] (pythia.bulinfo.net [212.72.195.5]) by mx.bulinfo.net (Postfix) with ESMTP id 082C615818; Wed, 2 Jan 2008 18:20:25 +0200 (EET) Message-ID: <477BB9C7.8080002@bulinfo.net> Date: Wed, 02 Jan 2008 18:20:23 +0200 From: Krassimir Slavchev User-Agent: Thunderbird 2.0.0.9 (X11/20071122) MIME-Version: 1.0 To: pluknet References: <476F7581.8080100@bulinfo.net> In-Reply-To: X-Enigmail-Version: 0.95.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: amavisd-new at mx.bulinfo.net Cc: FreeBSD Subject: Re: ifconfig options? X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Jan 2008 16:20:29 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi, This patch fixes the problem! # ifconfig -l bce0 bce1 lo0 # ifconfig -l ether bce0 bce1 Thanks pluknet wrote: > Hi, > > On 24/12/2007, Krassimir Slavchev wrote: >> 'ifconfig -l [address_family]' does not work correct on RELENG_7 >> >> >> FreeBSD 6.3-BETA2: >> # ifconfig -l >> em0 em1 plip0 lo0 pflog0 >> >> #ifconfig -l ether >> em0 em1 >> >> But: >> FreeBSD 7.0-BETA4: >> # ifconfig -l >> em0 em1 plip0 lo0 pflog0 >> >> #ifconfig -l ether >> em0 em1 plip0 lo0 pflog0 >> >> I need this functionality to get all ethernet interfaces. Is there other >> way to do this? >> > > To revert this functionality try this patch please. > > --- /usr/src/sbin/ifconfig/ifconfig.c 2007-12-26 23:25:17.000000000 +0300 > +++ /tmp/ifconfig.c 2007-12-26 23:18:53.000000000 +0300 > @@ -298,9 +298,12 @@ > * Are we just listing the interfaces? > */ > if (namesonly) { > - if (ifindex > 1) > - printf(" "); > - fputs(name, stdout); > + if (afp == NULL || afp->af_af != AF_LINK || > + sdl->sdl_type == IFT_ETHER) { > + if (ifindex > 1) > + printf(" "); > + fputs(name, stdout); > + } > continue; > } > -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (FreeBSD) iD8DBQFHe7nGxJBWvpalMpkRAn7MAKCsjDSf+uDsMQaH1Wxh09TsP43k5wCcDksO XPkb7nNG2p0wo6XvlvZlb+E= =p0rg -----END PGP SIGNATURE-----