commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1568691 - in /commons/proper/fileupload/trunk/src: changes/changes.xml main/java/org/apache/commons/fileupload/disk/DiskFileItem.java
Date Sat, 15 Feb 2014 22:02:48 GMT
Author: sebb
Date: Sat Feb 15 22:02:47 2014
New Revision: 1568691

URL: http://svn.apache.org/r1568691
Log:
FILEUPLOAD-244 DiskFileItem.readObject fails to close FileInputStream

Modified:
    commons/proper/fileupload/trunk/src/changes/changes.xml
    commons/proper/fileupload/trunk/src/main/java/org/apache/commons/fileupload/disk/DiskFileItem.java

Modified: commons/proper/fileupload/trunk/src/changes/changes.xml
URL: http://svn.apache.org/viewvc/commons/proper/fileupload/trunk/src/changes/changes.xml?rev=1568691&r1=1568690&r2=1568691&view=diff
==============================================================================
--- commons/proper/fileupload/trunk/src/changes/changes.xml (original)
+++ commons/proper/fileupload/trunk/src/changes/changes.xml Sat Feb 15 22:02:47 2014
@@ -45,6 +45,7 @@ The <action> type attribute can be add,u
   <body>
     <release version="1.4" date="TBA" description=
 "TBA">
+      <action issue="FILEUPLOAD-244" dev="sebb" type="fix">DiskFileItem.readObject
fails to close FileInputStream</action>
       <action issue="FILEUPLOAD-246" dev="sebb" type="update">FileUpload should use
IOUtils.closeQuietly where relevant</action>
       <action issue="FILEUPLOAD-245" dev="sebb" type="fix">DiskFileItem.get() may not
fully read the data</action>
       <action issue="FILEUPLOAD-243" dev="sebb" type="update" due-to="Ville Skyttä">Make
some MultipartStream private fields final</action>

Modified: commons/proper/fileupload/trunk/src/main/java/org/apache/commons/fileupload/disk/DiskFileItem.java
URL: http://svn.apache.org/viewvc/commons/proper/fileupload/trunk/src/main/java/org/apache/commons/fileupload/disk/DiskFileItem.java?rev=1568691&r1=1568690&r2=1568691&view=diff
==============================================================================
--- commons/proper/fileupload/trunk/src/main/java/org/apache/commons/fileupload/disk/DiskFileItem.java
(original)
+++ commons/proper/fileupload/trunk/src/main/java/org/apache/commons/fileupload/disk/DiskFileItem.java
Sat Feb 15 22:02:47 2014
@@ -665,6 +665,7 @@ public class DiskFileItem
         } else {
             FileInputStream input = new FileInputStream(dfosFile);
             IOUtils.copy(input, output);
+            input.close();
             dfosFile.delete();
             dfosFile = null;
         }



Mime
View raw message