From owner-freebsd-standards Mon Mar 4 21:41:37 2002 Delivered-To: freebsd-standards@freebsd.org Received: from espresso.q9media.com (espresso.q9media.com [216.254.138.122]) by hub.freebsd.org (Postfix) with ESMTP id 5250637B400 for ; Mon, 4 Mar 2002 21:41:35 -0800 (PST) Received: (from mike@localhost) by espresso.q9media.com (8.11.6/8.11.6) id g255ZvV96442; Tue, 5 Mar 2002 00:35:57 -0500 (EST) (envelope-from mike) Date: Tue, 5 Mar 2002 00:35:57 -0500 From: Mike Barcroft To: Garance A Drosihn Cc: freebsd-standards@FreeBSD.org Subject: Re: netinet/in.h vs arpa/inet.h Message-ID: <20020305003557.C33110@espresso.q9media.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: ; from drosih@rpi.edu on Tue, Mar 05, 2002 at 12:31:11AM -0500 Organization: The FreeBSD Project Sender: owner-freebsd-standards@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Garance A Drosihn writes: > Now that I've finally got myself switched over to 5.0-current, > I'm getting back to some lpr changes. I notice that if I > compile lpr with -Wredundant-decls, I get a few warnings from > source files which have: > > #include > #include > > Eg: > /usr/include/arpa/inet.h:127: warning: redundant redeclaration of > `__htonl' in same scope > /usr/include/machine/endian.h:67: warning: previous declaration of `__htonl' > > (plus similar warnings for __htons __ntohl __ntohs) > > Now, I find I can just comment out the include for arpa/inet.h, > and everything compiles OK (on both current and stable, if I've > tested correctly..). On the other hand, I do not get these > warnings even if I compile with -Wredundant-decls on -stable. > > Should I just remove the arpa/inet.h, or does this indicate that > something isn't quite perfect with the recent changes to various > include files under -current? This should be fixed shortly. The problem mainly stems from POSIX's requirements for the ntohl() family of functions to be defined in multiple headers. Best regards, Mike Barcroft To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-standards" in the body of the message