Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 16 Sep 2002 14:59:41 -0700 (PDT)
From:      Archie Cobbs <archie@dellroad.org>
To:        Garrett Wollman <wollman@lcs.mit.edu>
Cc:        Bruce M Simpson <bms@spc.org>, freebsd-net@FreeBSD.ORG
Subject:   Re: Proposal: adopt SIOCGLIFNUM interface for enumerating iflist.
Message-ID:  <200209162159.g8GLxfe88208@arch20m.dellroad.org>
In-Reply-To: <200209161712.g8GHCWak023802@khavrinen.lcs.mit.edu> "from Garrett Wollman at Sep 16, 2002 01:12:32 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
Garrett Wollman writes:
> > At this time these applications have to play 'elastic buffer' games with the
> > SIOCGIFCONF ioctl in order to get all of the relevant information. By allowing
> > userland applications to determine the size of this buffer at runtime, we
> > eliminate the need for repeated calls to ifioctl().
> 
> We have already done so: sysctl net.route.iflist.

FYI,
libpdel (ports:devel/libpdel) has code that shows how to do this
and makes it easier. Install the port and type 'man if_get_list'
for details.

-Archie

__________________________________________________________________________
Archie Cobbs     *     Packet Design     *     http://www.packetdesign.com

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200209162159.g8GLxfe88208>