curl-users
Re: Can't seem to transfer binary type
Date: Mon, 17 Jun 2002 20:15:31 +0200 (MET DST)
On Mon, 17 Jun 2002, Poulson, Shawn wrote:
> I'm using libcurl via Perl using the Curl::easy module on a Win32 platform.
> I don't seem to have a problem downloading files, however they always come
> down with the line endings translated from Unix to Dos type, regardless of
> the file I select. The Verbose description shows "TYPE I", but the file
> sizes are different and binary files are corrupt.
CURLOPT_CRLF is the only thing left then that might be fiddling with your
data. If you haven't used that, then I feel like blaming this on the ftp
server...
> This happens regardless of the setting of CURLOPT_TRANSFERTEXT.
But then you get "TYPE A", right?
> Any ideas what I can do?
Does this work with a "plain" ftp client?
> > RETR mbox
> * Getting file with size: 436497
> * Connection #0 left intact
> * Closing connection #0
> Done. (449088 bytes)
>
> Note "Getting file with size" versus "Done .. bytes" difference.
That also points to CURLOPT_CRLF or that the server sends more data than it
initially said it would.
-- Daniel Stenberg -- curl groks URLs -- http://curl.haxx.se/ _______________________________________________________________ Sponsored by: ThinkGeek at http://www.ThinkGeek.com/Received on 2002-06-17