You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Gary D. Gregory (Jira)" <ji...@apache.org> on 2021/06/30 13:56:00 UTC

[jira] [Updated] (IO-741) FileUtils.listFiles does not list matching files if File parameter is a symbolic link

     [ https://issues.apache.org/jira/browse/IO-741?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gary D. Gregory updated IO-741:
-------------------------------
    Summary: FileUtils.listFiles does not list matching files if File parameter is a symbolic link  (was: FileUtils.listFiles does not list matching files if File parameter is a symlink)

> FileUtils.listFiles does not list matching files if File parameter is a symbolic link
> -------------------------------------------------------------------------------------
>
>                 Key: IO-741
>                 URL: https://issues.apache.org/jira/browse/IO-741
>             Project: Commons IO
>          Issue Type: Bug
>          Components: Utilities
>    Affects Versions: 2.9.0, 2.10.0
>            Reporter: Zach Sherman
>            Priority: Major
>
> This is a regression from 2.6.0.  We are using the following FileUtils utility function to list matching files under a directory:
> {noformat}
> public static Collection<File> listFiles(File directory, String[] extensions, boolean recursive){noformat}
>  
> In particular the call we are making is:
> {noformat}
> FileUtils.listFiles(extension, new String[]{"jar"}, false);{noformat}
> This used to return all matching files in 2.6.0 when the directory was a symlink, but it no longer does. Breaking through the code in a debugger, I was able to manually add the FileVisitOptions.FOLLOW_LINKS option, but this is not specifiable from an external caller outside of commons-io.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)