Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
399 views
in edtFTPnet by (120 points)
edited by

If the FTP server's locale is not set to en_us then client.Exists(...) function throws exception :

Unable to determine if file '...' exists

The problem is that when it checks if the file exists it waits something like this as response from the server

550 .../.../.../file.ext: No such file or directory

but the "No such file or directory" part is translated to server's locale so it throws exception.

That would be nice if edtftp could work with any lang or if there would be any information in wikis about this bug.

Here is the response from debug log with locale hu_HU.utf8

DEBUG [FTPControlSocket] 5 okt. 2016 15:36:25.071 : 550 .../.../.../....pdf: Nincs ilyen f????jl vagy k??¶nyvt????r
WARN [FTPClient] 5 okt. 2016 15:36:25.071 : Unable to determine if file .../.../.../....pdf exists.

Workaround on linux (proftpd):

  1. edit the /etc/proftpd/proftpd.conf file
  2. set/add  LangDefault en_US

1 Answer

0 votes
by (161k points)
There is a property for adding your own messages to check for existence - see FileNotFoundMessages.

Unfortunately the FTP protocol didn't define a specific error code for file not found, so there is no consistent way to detect if a file wasn't found.

Categories

...