cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: libcurl putting empty file on Mac OS X

From: Josh Anon <josha_at_pixar.com>
Date: Thu, 18 Dec 2003 09:01:17 -0800

> Try typecasting the st_size to a (long) when you set it with
> INFILESIZE, as
> it is of type off_t on multiple platforms:
>
> curl_easy_setopt(curl, CURLOPT_INFILESIZE, (long)struct.st_size);
>

That did the trick. Come to think of it now, I remember something
where Mac OS X automatically gives you large file support, and an off_t
was an array of 2 32-bit values (or something like that), so this makes
sense.

Thanks!
Josh

---
Josh Anon
Studio Tools, Pixar Animation Studios
josha_at_pixar.com
-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
Received on 2003-12-18