httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tony Finch <...@dotat.at>
Subject Re: [PATCH] potential fix for the APR_OFF_T_FMT warning
Date Fri, 30 Jun 2000 13:35:24 GMT
From: Jeff Trawick <trawick@ibm.net> wrote:
>
>On FreeBSD, off_t is int whereas on Linux it is long.

No, it's 64 bits on all BSDs, i.e. long long or equivalent -- for some
reason with gcc on FreeBSD on i386 it's
	typedef int __attribute__((__mode__(__DI__))) __int64_t;
(possibly to make it work in ANSI BDSM mode)

>Frankly, I think your earlier suggesting about hardcoding it per
>platform may part of the clearest solution.

I expect the patch will work on most platforms, except perhaps 64 bit
platforms where these types are declared as long instead of long long
:-)

>By the way...   Add AP_SSIZE_T_FMT while you're at it :)

ssize_t is more usually 32 bits so I'd expect the analogous patch to
work even better for it.

Tony.
-- 
f.a.n.finch    fanf@covalent.net    dot@dotat.at
446 backflip from the balcony

Mime
View raw message