commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel Savarese (JIRA)" <j...@apache.org>
Subject [jira] Resolved: (NET-143) FTPClient.listFiles(String pathname) returns no entry on RH AS 4
Date Wed, 13 Dec 2006 19:14:24 GMT
     [ http://issues.apache.org/jira/browse/NET-143?page=all ]

Daniel Savarese resolved NET-143.
---------------------------------

    Resolution: Invalid

> FTPClient.listFiles(String pathname) returns no entry on RH AS 4
> ----------------------------------------------------------------
>
>                 Key: NET-143
>                 URL: http://issues.apache.org/jira/browse/NET-143
>             Project: Commons Net
>          Issue Type: Bug
>    Affects Versions: 1.4 Final
>         Environment: RedHat AS 4
>            Reporter: Felix Wong
>
> The following code snippet works fine on RedHat AS 3 ftp server.  However, it only works
on the top level of a RedHat AS 4 ftp server (e.g. ftp://myftpserver) but not on any subdirectory.
 ftpClient.listFiles(url.getPath()) return an empty array on any subdirectory (e.g. ftp://myftpserver/abc).
>     	URL url = new URL(urlString);
>     	FTPClient ftpClient = new FTPClient();
>         FTPFile[] ftpFiles;
>     	
> 	ftpClient.connect(url.getHost());
> 	ftpClient.login(username, password);
> 	int rc = ftpClient.getReplyCode();
>    	if (!FTPReply.isPositiveCompletion(rc)) {
>     		throw new Exception(ftpClient.getReplyString());
>     	}
>     	ftpFiles = ftpClient.listFiles(url.getPath());

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message