Received: by mail.netbsd.org (Postfix, from userid 605) id EA8C914A320; Tue, 17 Dec 2013 20:47:34 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id EBF6114A316 for ; Tue, 17 Dec 2013 20:47:33 +0000 (UTC) X-Virus-Scanned: amavisd-new at NetBSD.org Received: from mail.netbsd.org ([127.0.0.1]) by localhost (mail.NetBSD.org [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id dmOrSchLYKJV for ; Tue, 17 Dec 2013 20:47:33 +0000 (UTC) Received: from cvs.netbsd.org (cvs.NetBSD.org [IPv6:2001:4f8:3:7:2e0:81ff:fe30:95bd]) by mail.netbsd.org (Postfix) with ESMTP id 2ED3714A312 for ; Tue, 17 Dec 2013 20:47:33 +0000 (UTC) Received: by cvs.netbsd.org (Postfix, from userid 500) id 2894496; Tue, 17 Dec 2013 20:47:33 +0000 (UTC) Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" MIME-Version: 1.0 Date: Tue, 17 Dec 2013 20:47:33 +0000 From: "Manuel Bouyer" Subject: CVS commit: [netbsd-6] src To: source-changes@NetBSD.org X-Mailer: log_accum Message-Id: <20131217204733.2894496@cvs.netbsd.org> Sender: source-changes-owner@NetBSD.org List-Id: source-changes.NetBSD.org Precedence: bulk Reply-To: source-changes-d@NetBSD.org Mail-Reply-To: "Manuel Bouyer" Mail-Followup-To: source-changes-d@NetBSD.org Module Name: src Committed By: bouyer Date: Tue Dec 17 20:47:33 UTC 2013 Modified Files: src/sys/netinet6 [netbsd-6]: nd6.c src/usr.sbin/ndp [netbsd-6]: ndp.c Log Message: Pull up following revision(s) (requested by martin in ticket #998): usr.sbin/ndp/ndp.c: revision 1.42 sys/netinet6/nd6.c: revision 1.146 Instead of voodo casts use simple byte pointer arithmetic and memcpy to create the "packed" binary format we pass out to userland when querying the router/prefix list. Simplify code to print the router/prefix list: use memcpy and local structs properly aligned on the stack to decode the binary format passed by the kernel - instead of (bogusly) assuming the format will obey all local alignement requirements. To generate a diff of this commit: cvs rdiff -u -r1.141.2.1 -r1.141.2.2 src/sys/netinet6/nd6.c cvs rdiff -u -r1.40 -r1.40.4.1 src/usr.sbin/ndp/ndp.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.