From owner-freebsd-bugs Tue Sep 3 22:10:13 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 31B7837B400 for ; Tue, 3 Sep 2002 22:10:09 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id E89CA43E6A for ; Tue, 3 Sep 2002 22:10:08 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g845A7JU069841 for ; Tue, 3 Sep 2002 22:10:07 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g845A706069840; Tue, 3 Sep 2002 22:10:07 -0700 (PDT) Date: Tue, 3 Sep 2002 22:10:07 -0700 (PDT) Message-Id: <200209040510.g845A706069840@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: Bruce Evans Subject: Re: bin/42385: clean libatm code from warnings Reply-To: Bruce Evans Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following reply was made to PR bin/42385; it has been noted by GNATS. From: Bruce Evans To: Dan Lukes Cc: FreeBSD-gnats-submit@FreeBSD.ORG Subject: Re: bin/42385: clean libatm code from warnings Date: Wed, 4 Sep 2002 15:06:44 +1000 (EST) On Tue, 3 Sep 2002, Dan Lukes wrote: > >Description: > lib/libatm/atm_addr.c: > 308: warning: long unsigned int format, __uint32_t arg (arg 3) > long unsigned int format, __uint32_t arg (arg 4) > #>> ntohl (despite of 'l' in it's name) > #>> return uint32_t ( = __uint32_t = unsigned int ) > #>> so 'l' modifier should not be used The format is correct. ntohl() returns a typedefed type which may be u_long. ntohl() still returns long or ulong on some systems like its name suggests. The values should be cast to u_long since the type is unknown. The type can be almost anything, but the values are known to be representable as u_longs. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message