On Tue, Mar 11, 2003 at 03:00:50PM +0100, Piotr Krukowiecki wrote:
> Sometimes when uploading files lftp stops on e.g
>
> `file' at 244808534 (100%) [Waiting for transfer to complete]
>
> and it waits and waits and waits and nothing happens.
> net:timeout is set to 120s but that doesn't help. So i suppose i
> want net:timeout to have influence on this as well.
Attached is the patch to fix it. Originally this was timeout-less,
because the data buffered on socket (e.g. 40k) could be transferred
very slowly (e.g. 10 bytes a second) and the progress cannot be seen
by lftp.
--
Alexander.
Index: ftpclass.cc
===================================================================
RCS file: /home/lav/cvsroot/lftp/src/ftpclass.cc,v
retrieving revision 1.257
diff -u -p -r1.257 ftpclass.cc
--- ftpclass.cc 28 Feb 2003 07:12:36 -0000 1.257
+++ ftpclass.cc 13 Mar 2003 11:11:22 -0000
@@ -2028,9 +2028,8 @@ int Ftp::Do()
TimeoutS(stat_time+stat_interval-now);
}
- // store mode is special - the data can be buffered
- // so is COPY_* - no data connection at all.
- if(mode==STORE || copy_mode!=COPY_NONE)
+ // FXP is special - no data connection at all.
+ if(copy_mode!=COPY_NONE)
goto notimeout_return;
goto usual_return;