commit | 6c3a1bb78c3e92fded50c1c1e9f4c3e2e6e9dd4c | [log] [tgz] |
---|---|---|
author | Gary D. Gregory <ggregory@apache.org> | Tue Apr 26 23:59:45 2016 +0000 |
committer | Gary D. Gregory <ggregory@apache.org> | Tue Apr 26 23:59:45 2016 +0000 |
tree | 9fc866d583a65f0a05fc9f3e22dff568b67d8bbb | |
parent | d9406824aeba0e977c0692971a6dbb2e62823886 [diff] |
[IO-502] Exceptions are suppressed incorrectly when copying files. git-svn-id: https://svn.apache.org/repos/asf/commons/proper/io/trunk@1741124 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/src/main/java/org/apache/commons/io/FileUtils.java b/src/main/java/org/apache/commons/io/FileUtils.java index d2efb6f..380d865 100644 --- a/src/main/java/org/apache/commons/io/FileUtils.java +++ b/src/main/java/org/apache/commons/io/FileUtils.java
@@ -1154,6 +1154,18 @@ } pos += bytesCopied; } + + output.close(); + output = null; + + fos.close(); + fos = null; + + input.close(); + input = null; + + fis.close(); + fis = null; } finally { IOUtils.closeQuietly(output, fos, input, fis); }