cURL / Mailing Lists / curl-library / Single Mail


Re: Helping apps use 64bit with libcurl

From: Michal Marek <>
Date: Mon, 26 May 2008 11:05:50 +0200

Dan Fandrich wrote:
> On Wed, May 21, 2008 at 10:21:04PM +0200, Daniel Stenberg wrote:
>> On Wed, 21 May 2008, Michal Marek wrote:
>>> In English: if building without LFS, make CURLOPT_POSTFIELDSIZE_LARGE
>>> equivalent to CURLOPT_POSTFIELDSIZE.
>> Yeah, that would be really neat.
>> Can we make that happen in a somewhat nice way in the headers?
> What about this scenario: libcurl is built without LFS, and the app is built
> with. The library will then be expecting a long while the app will be
> providing a long long.

Right, in this case, libcurl is lost. But if we do the above change in
the header, then passing the real CURLOPT_POSTFIELDSIZE_LARGE code can
be considered an error, because this means that in the application
sizeof(curl_off_t) == 8.

Well, almost. Currently, the programmer can hardcode the 30120 option
code and pass the correct type... :-(

Received on 2008-05-26