commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sebb (JIRA)" <j...@apache.org>
Subject [jira] [Created] (IO-386) FileUtils.doCopyFile uses different methods to check the file sizes
Date Sun, 02 Jun 2013 13:39:20 GMT
Sebb created IO-386:
-----------------------

             Summary: FileUtils.doCopyFile uses different methods to check the file sizes
                 Key: IO-386
                 URL: https://issues.apache.org/jira/browse/IO-386
             Project: Commons IO
          Issue Type: Bug
            Reporter: Sebb
            Priority: Minor


FileUtils.doCopyFile uses FileChannel.size() to measure the input file length at the start,
and File.length() to compare the lengths at the end.

This is inconsistent.
If there is a good reason for this it should be documented, otherwise it should probably use
the same method for all the checks.
[Note: is FileChannel.size() accurate if the file has not been flushed?]

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

Mime
View raw message