cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: LONG_MAX patch

From: Daniel Stenberg <daniel-curl_at_haxx.se>
Date: Fri, 16 Jan 2004 09:23:11 +0100 (CET)

On Thu, 15 Jan 2004, Mark Pizzolato wrote:

> Well,you could use the undocumented i64() interfaces mentioned below, hoever
> there really aren't include files which document them. They are, by design,
> for internal use of the CRTL.
>
> Meanwhile, the clean way to do this on windows is to either directly or
> indirectly use: fgetpos(), and fsetpos(). As it turns out, on Win32
> environments, a pos_t is an int64, writing a Win32 specific fseeko() wrapper
> function is sort of trivial.

The problem with large files in libcurl is not seeking in local files. libcurl
needs to be able to get >32 bit numbers from the application/servers, to keep
>32 bit file sizes internally and to pass on >32 bit numbers to servers.

We currently use off_t for this, which clearly isn't good enough. Since we
don't pass this on to local I/O functions, perhaps we can simply use 'pos_t'
on windows and get away with it?

-- 
    Daniel Stenberg -- http://curl.haxx.se/ -- http://daniel.haxx.se/
   [[ Do not send mails to this email address. They won't reach me. ]]
-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
Received on 2004-01-16