cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: libcurl: SFTP Sample Code with LARGE operations

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Mon, 5 Jul 2010 19:47:42 +0200 (CEST)

On Sat, 3 Jul 2010, Paul Romero wrote:

> I could not get an SFTP test program--generated with curl, to work correctly
> in my environment which is a Debian Linux i686 Lenny machine with Pentium 4
> CPU. It also has version 4.1.2 of the GCC GNU compiler installed.

> curl_easy_setopt(hnd, CURLOPT_INFILESIZE_LARGE, -1);

Ouch, This is wrong. You shouldn't pass in just -1 there. Remove that whole
line instead.

All lines that passes in a curl_off_t actually should get a proper typecast
(or LL suffix or similar), as just using a value like that will not be 64bit
clean.

-- 
  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2010-07-05