FILEUPLOAD-251 DiskFileItem#getTempFile() is broken
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/fileupload/trunk@1568874 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/src/changes/changes.xml b/src/changes/changes.xml
index 2ecdb53..ebf4a71 100644
--- a/src/changes/changes.xml
+++ b/src/changes/changes.xml
@@ -45,6 +45,7 @@
<body>
<release version="1.4" date="TBA" description=
"TBA">
+ <action issue="FILEUPLOAD-251" dev="sebb" type="fix">DiskFileItem#getTempFile() is broken</action>
<action issue="FILEUPLOAD-250" dev="sebb" type="fix">FileUploadBase - potential resource leak - InputStream not closed on exception</action>
<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>
diff --git a/src/main/java/org/apache/commons/fileupload/disk/DiskFileItem.java b/src/main/java/org/apache/commons/fileupload/disk/DiskFileItem.java
index 0eb56b4..ff61288 100644
--- a/src/main/java/org/apache/commons/fileupload/disk/DiskFileItem.java
+++ b/src/main/java/org/apache/commons/fileupload/disk/DiskFileItem.java
@@ -554,6 +554,9 @@
* named temporary file in the configured repository path. The lifetime of
* the file is tied to the lifetime of the <code>FileItem</code> instance;
* the file will be deleted when the instance is garbage collected.
+ * <p>
+ * <b>Note: Subclasses that override this method must ensure that they return the
+ * same File each time.</b>
*
* @return The {@link java.io.File File} to be used for temporary storage.
*/