From owner-cvs-src@FreeBSD.ORG Thu Apr 3 22:56:11 2003 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 789C537B401; Thu, 3 Apr 2003 22:56:11 -0800 (PST) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6D68943FBF; Thu, 3 Apr 2003 22:56:10 -0800 (PST) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.9/8.12.9) with ESMTP id h346twLd005568; Fri, 4 Apr 2003 08:56:08 +0200 (CEST) (envelope-from phk@phk.freebsd.dk) To: Nate Lawson From: "Poul-Henning Kamp" In-Reply-To: Your message of "Thu, 03 Apr 2003 15:49:08 -0800." Date: Fri, 04 Apr 2003 08:55:58 +0200 Message-ID: <5567.1049439358@critter.freebsd.dk> cc: cvs-src@FreeBSD.org cc: src-committers@FreeBSD.org cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/sys endian.h src/share/man/man9 byteorder.9 X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 04 Apr 2003 06:56:11 -0000 In message , Nate Lawson wri tes: >On Thu, 3 Apr 2003, Poul-Henning Kamp wrote: >> Modified files: >> sys/sys endian.h >> share/man/man9 byteorder.9 >> Log: >> Add inline functions {be,le}{16,32,64}{enc,dec}() for encoding decoding >> into byte strings of unknown alignment. >> >> Revision Changes Path >> 1.3 +39 -1 src/share/man/man9/byteorder.9 >> 1.3 +108 -0 src/sys/sys/endian.h > >This is really great! I have wanted this for a while. Just a few >questions. Have the standards folks had a look at the API? Second, it >appears the *enc functions have args in reverse order (void *, uint32_t >for example). Any thoughts on bcopy vs. memcpy ordering of args? I don't particularly care about the order, so if there is a concensus for one order over the other I'll just change it. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.