You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Sebb (JIRA)" <ji...@apache.org> on 2013/07/10 14:13:49 UTC
[jira] [Resolved] (IO-389) FileUtils.sizeOfDirectory can throw
IllegalArgumentException
[ https://issues.apache.org/jira/browse/IO-389?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Sebb resolved IO-389.
---------------------
Resolution: Fixed
Fix Version/s: 2.5
Thanks for the report and patch.
IO-390 was fixed using the private method technique (new methods were needed for that anyway) so decided to use the same technique here.
URL: http://svn.apache.org/r1501744
Log:
IO-389 FileUtils.sizeOfDirectory can throw IllegalArgumentException
Modified:
commons/proper/io/trunk/src/changes/changes.xml
commons/proper/io/trunk/src/main/java/org/apache/commons/io/FileUtils.java
> FileUtils.sizeOfDirectory can throw IllegalArgumentException
> ------------------------------------------------------------
>
> Key: IO-389
> URL: https://issues.apache.org/jira/browse/IO-389
> Project: Commons IO
> Issue Type: Bug
> Reporter: Austin Doupnik
> Priority: Minor
> Fix For: 2.5
>
> Attachments: IO-389.patch
>
>
> FileUtils.sizeOfDirectory has a small concurrency issue. Between the call to File.listFiles and the call to FileUtils.sizeOf, a file may be deleted. This can cause FileUtils.sizeOf to throw an IllegalArgumentException, indicating that the file does not exist.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira