Menu

#2 from ftp with subdir "."

open
nobody
None
5
2008-04-08
2008-04-08
Pat
No

Hello,

I am trying to synchronise from ftp to file.

It look like the "." directory is considered as a subdirectory on the ftp part.

For example, with "from address" = "ftp://my_ftp_server.fr/test", I get the following result.

Connecting to the FTP server: my_ftp_server.fr
Connected to my_ftp_server.fr
LIST /test/
LIST /test/.
LIST /test/./.
LIST /test/././.
LIST /test/./././.
LIST /test/././././.
LIST /test/./././././.
LIST /test/././././././.
LIST /test/./././././././.
LIST /test/././././././././.
LIST /test/./././././././././.
LIST /test/././././././././././.
LIST /test/./././././././././././.
LIST /test/././././././././././././.
LIST /test/./././././././././././././.
LIST /test/././././././././././././././.
LIST /test/./././././././././././././././.
LIST /test/././././././././././././././././.

To correct this, I suggest that you change line 94 in "file_list.php":
Replace: if ($d == 'd')
By: if ( ($d == 'd') && ($n != ".") && ($n != "..") )

Think you for this tool

Discussion


Log in to post a comment.

MongoDB Logo MongoDB