cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re[5]: >2 GB file support

From: Vladimir Trebicky <trebicky_at_xhost.cz>
Date: Tue, 19 Aug 2003 15:45:12 +0200

VT> It is much more complicated. There must be some incompatible
VT> conversion which occures during the progress where
VT> data->set.infilesize is set. Unfortunately, I cannot solve _where_
VT> it occures. I tried to convert some other variables
VT> such as bytecountp, gottensize, downloadsize but none of it helped.

Curl_ftp_done() isn't called before the connection is closed, so

    if((-1 != data->set.infilesize) &&
       (data->set.infilesize != *ftp->bytecountp) &&
       !data->set.crlf) {
      failf(data, "Uploaded unaligned file size (%d out of %d bytes)",
            *ftp->bytecountp, data->set.infilesize);
      return CURLE_PARTIAL_FILE;
    }

(that return CURLE_PARTIAL_FILE) stopped executing the function and
clean closing the socket which sometimes caused that some bytes at the
end of the file wasn't delivered.

I commented this "if" out.

That set.infilesize is many times set by another variables which are
not int64. Unfortunately, it is a huge amount or variables. Many of
them are defined as a part or some function, some of them cannot be
retyped (as filesize_t). I hope someone who knows the code better than
me shall fix this ;-)

-- 
S pozdravem,
 Vladimir Trebicky                            mailto:trebicky_at_xhost.cz
-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01
Received on 2003-08-19