On Wed, Jan 22, 2003 at 11:45:35AM +0100, seb wrote:
> http://bugs.proftpd.org/show_bug.cgi?id=1931
>
> proftpd guys conclude that the nlst probleme result from a bug in lftp.
> if someone has time ...

Does this lftp patch fix the problem?

--
   Alexander.
Index: ftpclass.cc
===================================================================
RCS file: /home/lav/cvsroot/lftp/src/ftpclass.cc,v
retrieving revision 1.253
diff -u -p -r1.253 ftpclass.cc
--- ftpclass.cc 25 Dec 2002 13:44:31 -0000      1.253
+++ ftpclass.cc 6 Feb 2003 11:12:13 -0000
@@ -2444,7 +2444,7 @@ void Ftp::SendUrgentCmd(const char *cmd)
 
 void  Ftp::DataAbort()
 {
-   if(control_sock==-1 || state==CONNECTING_STATE)
+   if(control_sock==-1 || state==CONNECTING_STATE || quit_sent)
       return;
 
    if(data_sock==-1 && copy_mode==COPY_NONE)
@@ -3069,6 +3069,12 @@ read_again:
            return DO_AGAIN;
         if(NotSerious(errno))
         {
+           if(errno==ECONNRESET && mode==LIST && real_pos==0)
+           {
+              // workaround for some proftpd servers.
+              DebugPrint("**** ",strerror(errno),0);
+              goto we_have_eof;
+           }
            DebugPrint("**** ",strerror(errno),0);
            quit_sent=true;
            Disconnect();

Reply via email to