curl-library
Re: FTP & NOBODY
Date: Mon, 20 Aug 2007 20:46:54 +0200
on 8/20/2007 8:09 PM, Christian Vogt wrote:
> Until then, would you think it is a save hotfix to call
> Curl_pgrsSetDownloadSize() from the implementation of the
> ftp_state_size_resp() routine in ftp.c?
I tried the little patch below (against 7.16.4), and it worked well for
my case. Can any of you imagine potential problems with it? (btw: the
revision number is from a local subversion repository... :)
Cheers,
Christian
Index: ftp.c
===================================================================
--- ftp.c (revision 2753)
+++ ftp.c (working copy)
@@ -2094,6 +2094,8 @@
if(instate == FTP_SIZE) {
if(-1 != filesize) {
+ Curl_pgrsSetDownloadSize(data, filesize);
snprintf(buf, sizeof(data->state.buffer),
"Content-Length: %" FORMAT_OFF_T "\r\n", filesize);
result = Curl_client_write(conn, CLIENTWRITE_BOTH, buf, 0);
Received on 2007-08-20