Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
4.9k views
in Java FTP by (240 points)
Hi,

We are using edtftpj-1.4.0.
When in the April month I call
dirDetails
in a directory that contains a subdirectory named "A", I receive the following information
(toString of FTPFile returned by dirDetails):
[Name=Apr 03 08:03 A,Size=4096,Permissions=null,Owner=505,Group=506,Is link=false,Is dir=true,Linked name=null,Permissions=null,Last modified=03-04-2008 08:03]
The name is "Apr 03 08:03 A"
It's very very strange!!

When in the April month I call
dirDetails
in a directory that contains a subdirectory named "Z", I receive the following information
(toString of FTPFile returned by dirDetails):
[Name=Z,Size=4096,Permissions=null,Owner=505,Group=506,Is link=false,Is dir=true,Linked name=null,Permissions=null,Last modified=03-04-2008 08:18]
The name is "Z". It is correct.

Could anyone please help me?
Thanks a lot!

6 Answers

0 votes
by (162k points)
If you connect to the FTP server via ftp.exe and type 'dir' and post the directory listing, we'll take a look. Every server returns a slightly different listing which has to be interpreted - there isn't a standard.
0 votes
by (240 points)
I hope it helps:
250 Directory successfully changed.
ftp> dir
200 PORT command successful. Consider using PASV.
150 Here comes the directory listing.
drwxr-xr-x    3 505      506          4096 Apr 04 13:29 A
226 Directory send OK.
ftp: 59 bytes received in 0.00Seconds 59000.00Kbytes/sec.
ftp> cd A
250 Directory successfully changed.
ftp> dir
200 PORT command successful. Consider using PASV.
150 Here comes the directory listing.
drwxr-xr-x    3 505      506          4096 Apr 04 13:29 B
226 Directory send OK.
ftp: 59 bytes received in 0.00Seconds 59000.00Kbytes/sec.
ftp>
0 votes
by (162k points)
which one succeeds & which one fails of the above?
0 votes
by (240 points)
According to the first message:
when the directory begins with a letter that is equals to the first letter of the month, then it fails.

i.e.:
ftp> dir
200 PORT command successful. Consider using PASV.
150 Here comes the directory listing.
drwxr-xr-x    3 505      506          4096 Apr 04 13:29 A 

fails because the return value of dirDetails is:
[Name=Apr 04 13:29 A, ...

instead of
[Name=A, ...


The second one
ftp> dir
200 PORT command successful. Consider using PASV.
150 Here comes the directory listing.
drwxr-xr-x    3 505      506          4096 Apr 04 13:29 B

succeeds
0 votes
by (162k points)
With the latest version it works fine.

1.4.0 is now almost 4 years old, and there are literally hundreds of bug fixes and enhancements since then. You should upgrade.

See http://www.enterprisedt.com/products/ed ... story.html for more details.
0 votes
by (240 points)
Thank you very much for your help. We will plan an upgrade.
P.S.: Don't forget to add this test case to your JUnit Tests :wink:

Categories

...