commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mario Ivankovits (JIRA)" <j...@apache.org>
Subject [jira] Resolved: (VFS-77) VFS cannot determine file type of root for FTP, prevents listing of children at root
Date Wed, 16 Aug 2006 14:23:15 GMT
     [ http://issues.apache.org/jira/browse/VFS-77?page=all ]

Mario Ivankovits resolved VFS-77.
---------------------------------

    Fix Version/s: Nightly Builds
       Resolution: Fixed

should be fixed now, please check it.

Thanks!
Ciao,
Mario

> VFS cannot determine file type of root for FTP, prevents listing of children at root
> ------------------------------------------------------------------------------------
>
>                 Key: VFS-77
>                 URL: http://issues.apache.org/jira/browse/VFS-77
>             Project: Commons VFS
>          Issue Type: Bug
>    Affects Versions: Nightly Builds
>         Environment: Windows, Eclipse, Java 1.5
> commons-vfs-20060808.zip
> commons-net-1.4.1.jar, etc. (not sure one of the dependencies is the real problem)
>            Reporter: Ben Ashpole
>             Fix For: Nightly Builds
>
>
> The following example, adapted from http://jakarta.apache.org/commons/vfs/api.html, throws
the below exception for the given, valid FTP site.  Please let me know if this issue can be
replicated!
>         FileSystemManager fsManager = VFS.getManager();
>         FileObject f = fsManager.resolveFile("ftp://ftp.uspto.gov/");
>         FileObject[] children = f.getChildren();  // exception thrown here
>         System.out.println("Children of "+f.getName().getURI());
>         for(int i = 0; i<children.length; i++)
>             {
>             System.out.println(children[i].getName().getBaseName());
>             }
> Exception in thread "main" org.apache.commons.vfs.FileSystemException: Could not determine
the type of file "ftp://ftp.uspto.gov/".
> 	at org.apache.commons.vfs.provider.AbstractFileObject.attach(AbstractFileObject.java:1281)
> 	at org.apache.commons.vfs.provider.AbstractFileObject.getType(AbstractFileObject.java:410)
> 	at org.apache.commons.vfs.provider.AbstractFileObject.getChildren(AbstractFileObject.java:523)
> 	at com.bashpole.reflectorGadget.reflectionGroup.Ftp.test(Ftp.java:55)
> 	at com.bashpole.reflectorGadget.reflectionGroup.Ftp.main(Ftp.java:24)
> Caused by: org.apache.commons.vfs.FileSystemException: Object didnt extend from AbstractFileObject.
Object "{0}"
> 	at org.apache.commons.vfs.util.FileObjectUtils.getAbstractFileObject(FileObjectUtils.java:50)
> 	at org.apache.commons.vfs.provider.ftp.FtpFileObject.getInfo(FtpFileObject.java:174)
> 	at org.apache.commons.vfs.provider.ftp.FtpFileObject.doAttach(FtpFileObject.java:166)
> 	at org.apache.commons.vfs.provider.AbstractFileObject.attach(AbstractFileObject.java:1267)
> 	... 4 more

-- 
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