|
I trying an execute a next code:
First, size1, is returned successfully, and second size2 is failed (on some servers) with FtpExceptionStatus.ProtocolError, "Requested action not taken. File doesnot exist (550).". But, client.GetFile() with a second path is succeed. Do you can to format a path into a canonical form within a Ftp class? |
|
Problem is that there is no "canonical form" of path in FTP protocol specification. Some FTP servers use only "/", some use only "\". Some allow both of them. And some may use a completely different directory separators. The safest way is to split directory change and GetFileLength into two separate call.
UPDATE:: Answer to "why GetFileLength is failed and GetFile no?" The It looks quite strange. Would it be possible to create a communication log from Rebex component (as described at rebex.net/kb/logging.aspx) and from FileZilla and either update your question or send it to support@rebex.net for analysis? Thanks! But, why GetFileLength is failed and GetFile no?
(29 Jul '10, 14:58)
_FRED_
@FRED, I've updated my answer and discussed the GetFileLength and GetFile differences.
(29 Jul '10, 16:16)
Martin Vobr ♦♦
|