[ https://issues.apache.org/jira/browse/VFS-175?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16477371#comment-16477371 ]
Philipp Brügger commented on VFS-175: ------------------------------------- This happens very rarely i.e. when using the local provider accessing samba shares within windows. Unfortunately I do not have a reproducable test-case, but it seems like the rootName variable can be null and creates the ugly NullPointerException instead the FileSystemException. > NullPointerException in AbstractFileSystem.resolveFile > ------------------------------------------------------ > > Key: VFS-175 > URL: https://issues.apache.org/jira/browse/VFS-175 > Project: Commons VFS > Issue Type: Bug > Affects Versions: 1.0 > Reporter: Andrew Franklin > Priority: Trivial > > 1. Prepare a large file that will take a while to transfer (> 2GB). > 2. Start an ftp file transfer. > 3. Once the transfer begins and you see the file start to grow on the > destination side, delete it. > If you try to transfer again after it fails, you can get the following > exception... > Caused by: org.apache.commons.vfs.FileSystemException: Could not determine > the type of file "ftp://anonymous:password@server/". > at > org.apache.commons.vfs.provider.AbstractFileObject.attach(AbstractFileObject.java:1345) > at > org.apache.commons.vfs.provider.AbstractFileObject.getType(AbstractFileObject.java:443) > at > org.apache.commons.vfs.provider.AbstractFileObject.exists(AbstractFileObject.java:433) > at > org.apache.commons.vfs.provider.AbstractFileObject.findFiles(AbstractFileObject.java:1055) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:585) > at > com.company.vfs.RetryRemoteFileSystemProxy.invoke(RetryRemoteFileSystemProxy.java:70) > at $Proxy1.findFiles(Unknown Source) > at > com.company.vfs.VfsFileSource.findMatchingSourceFiles(VfsFileSource.java:216) > at com.company.vfs.VfsFileSource.discover(VfsFileSource.java:191) > ... 5 more > Caused by: java.lang.NullPointerException > at > org.apache.commons.vfs.provider.AbstractFileSystem.resolveFile(AbstractFileSystem.java:272) > at > org.apache.commons.vfs.provider.AbstractFileSystem.resolveFile(AbstractFileSystem.java:267) > at > org.apache.commons.vfs.provider.AbstractFileObject.getParent(AbstractFileObject.java:543) > at > org.apache.commons.vfs.provider.ftp.FtpFileObject.getInfo(FtpFileObject.java:182) > at > org.apache.commons.vfs.provider.ftp.FtpFileObject.doAttach(FtpFileObject.java:174) > at > org.apache.commons.vfs.provider.AbstractFileObject.attach(AbstractFileObject.java:1331) > ... 16 more -- This message was sent by Atlassian JIRA (v7.6.3#76005)