From owner-freebsd-hackers Tue Jan 9 6:21: 4 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from salmon.maths.tcd.ie (salmon.maths.tcd.ie [134.226.81.11]) by hub.freebsd.org (Postfix) with SMTP id B4D9F37B400 for ; Tue, 9 Jan 2001 06:20:44 -0800 (PST) Received: from walton.maths.tcd.ie by salmon.maths.tcd.ie with SMTP id ; 9 Jan 2001 14:20:44 +0000 (GMT) Date: Tue, 9 Jan 2001 14:20:43 +0000 From: David Malone To: Graham Wheeler Cc: freebsd-hackers@freebsd.org, markster@marko.net Subject: Re: Size of struct ifreq/returned buffer of SIOCGIFCONF Message-ID: <20010109142043.B52761@walton.maths.tcd.ie> References: <3A5AE854.F769B86C@cequrux.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <3A5AE854.F769B86C@cequrux.com>; from gram@cequrux.com on Tue, Jan 09, 2001 at 12:30:44PM +0200 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Tue, Jan 09, 2001 at 12:30:44PM +0200, Graham Wheeler wrote: > Just a follow up on this: on Stevens vol 2 pg 117, code line 299, is the > implication that the returned buffer DOES hold an array of struct ifreq > elements. So this does seem to indicate that something may be broken on > FreeBSD. At the very least there is some ambiguity - is this an array of > struct ifreq's, or an array of struct ifreq's at 36 byte intervals? If you read the paragraph below that code, it notes that the ifreq structures are of variable length. The spacing depends on the size of the returned info. David. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message