Please try this patch.
--
Alexander.
Index: ftpclass.cc
===================================================================
RCS file: /home/lav/cvsroot/lftp/src/ftpclass.cc,v
retrieving revision 1.379
diff -u -p -r1.379 ftpclass.cc
--- ftpclass.cc 19 Apr 2006 09:48:06 -0000 1.379
+++ ftpclass.cc 23 Apr 2006 18:30:51 -0000
@@ -1303,14 +1303,10 @@ int Ftp::Do()
conn->SavePeerAddress();
#if USE_SSL
-
if(proxy?!xstrcmp(proxy_proto,"ftps")||!xstrcmp(proxy_proto,"https"):ftps)
+ if(proxy && (!xstrcmp(proxy_proto,"ftps")
+ || !xstrcmp(proxy_proto,"https")))
{
conn->MakeSSLBuffers(hostname);
- if(ftps)
- {
- const char
*initial_prot=ResMgr::Query("ftps:initial-prot",hostname);
- conn->prot=initial_prot[0];
- }
}
else // note the following block
#endif
@@ -1330,6 +1326,12 @@ int Ftp::Do()
goto usual_return;
pre_CONNECTED_STATE:
+ if(ftps && (!proxy || conn->proxy_is_http))
+ {
+ conn->MakeSSLBuffers(hostname);
+ const char *initial_prot=ResMgr::Query("ftps:initial-prot",hostname);
+ conn->prot=initial_prot[0];
+ }
if(use_telnet_iac)
conn->InitTelnetLayer();