Date: Tue, 19 Mar 2002 15:41:57 +1100 (EST) From: Bruce Evans <bde@zeta.org.au> To: Peter Wemm <peter@wemm.org> Cc: Bruce Evans <bde@FreeBSD.org>, <cvs-committers@FreeBSD.org>, <cvs-all@FreeBSD.org> Subject: Re: cvs commit: src/sys/dev/amr amr.c Message-ID: <20020319153037.A4516-100000@gamplex.bde.org> In-Reply-To: <20020319010146.B1F17390B@overcee.wemm.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 18 Mar 2002, Peter Wemm wrote: > Bruce Evans wrote: > > bde 2002/03/18 15:24:00 PST > > > > Modified files: > > sys/dev/amr amr.c > > Log: > > Fixed printf format errors in previous commit. %llu is no more suitable > > than %u for printing signed 64-bit types. It fails on different machines, > > and has the wrong signdness. > > Also, 64 bit types are not 'long long' on all of our 64 bit platforms. > They are plain %ld o4 %lu. I think int64_t == "long long" is the unusual case for 64-bit arches. %qd is no better, since although int64_t == quad_t for must arches, %q is not suitable for printing quad_t's. gcc's format checker thinks it is an alias for %ll, and printf(3) now agrees (printf(3) doesn't use quad_t internally, in preparation for fully deprecating it). Th fix should use %jd, since it really wants to use a maximal integral type, but %j is not available yet (it is is in printf(3), but not in the kernel, and gcc-2 doesn't understand it). Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020319153037.A4516-100000>