From owner-freebsd-net Thu Oct 10 12:15:14 2002 Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D67D437B404; Thu, 10 Oct 2002 12:15:12 -0700 (PDT) Received: from InterJet.dellroad.org (adsl-63-194-81-26.dsl.snfc21.pacbell.net [63.194.81.26]) by mx1.FreeBSD.org (Postfix) with ESMTP id 46D3E43E9E; Thu, 10 Oct 2002 12:15:12 -0700 (PDT) (envelope-from archie@dellroad.org) Received: from arch20m.dellroad.org (arch20m.dellroad.org [10.1.1.20]) by InterJet.dellroad.org (8.9.1a/8.9.1) with ESMTP id MAA70665; Thu, 10 Oct 2002 12:11:31 -0700 (PDT) Received: from arch20m.dellroad.org (localhost [127.0.0.1]) by arch20m.dellroad.org (8.12.6/8.12.6) with ESMTP id g9AJAMON013105; Thu, 10 Oct 2002 12:10:23 -0700 (PDT) (envelope-from archie@arch20m.dellroad.org) Received: (from archie@localhost) by arch20m.dellroad.org (8.12.6/8.12.6/Submit) id g9AJAMQj013104; Thu, 10 Oct 2002 12:10:22 -0700 (PDT) From: Archie Cobbs Message-Id: <200210101910.g9AJAMQj013104@arch20m.dellroad.org> Subject: Re: Parsing route dump received using sysctl In-Reply-To: <20021004162657.GB91159@sunbay.com> "from Ruslan Ermilov at Oct 4, 2002 07:26:57 pm" To: Ruslan Ermilov Date: Thu, 10 Oct 2002 12:10:22 -0700 (PDT) Cc: yatin chalke , freebsd-net@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL88 (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Ruslan Ermilov writes: > > I am currently trying to get a route dump in > > freebsd4.4 using sysctl with NET_RT_DUMP. > > > > I am running into problems while parsing the returned > > rt_msghdr structures. > > Look at the route(8) code, you're probably missing the > necessary alignments (with the ROUNDUP() macro). Alternately, use the uroute(3) routines in the devel/libpdel port.. http://www.dellroad.org/manpage?page=uroute -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