The GitHub Actions job "Java CI" on commons-vfs.git/master has failed. Run started by GitHub user garydgregory (triggered by garydgregory).
Head commit for run: 50b4c72ff081e44d6e93f8a9f5d96b80aead9e01 / Ilan Goldfeld <[email protected]> Fix FtpFileObject.exists() returning true for root-level folders after connection drop (#757) * [VFS] Fix FtpFileObject.exists() returning true for root-level folders after connection drop setFTPFile() blindly assumed that root-level directories (where getParent() returns null) always exist by creating a synthetic FTPFile with DIRECTORY_TYPE. This caused exists() to return true even after the FTP connection was lost. Fix: add verifyRootDirectory() which uses CWD "." to verify the directory exists on the server. CWD "." checks the current directory (the logical VFS root) which is correct for both configurations: - userDirIsRoot=true: current dir is the user's login directory - userDirIsRoot=false: current dir is "/" (set by the factory CWD) Using "." rather than "/" avoids a semantic mismatch on non-chroot servers with userDirIsRoot=true, where "/" would go to the actual server root instead of the user's login directory. Add FtpClient.changeDirectory() default method and FTPClientWrapper implementation to support CWD from FtpFileObject. * Fix Javadoc since tag. --------- Co-authored-by: Gary Gregory <[email protected]> Report URL: https://github.com/apache/commons-vfs/actions/runs/24002843200 With regards, GitHub Actions via GitBox
