Infinite loop in FileUtils.getDefaultTempDir() when "java.io.tmpdir" directory
does not exist
---------------------------------------------------------------------------------------------
Key: CXF-1924
URL: https://issues.apache.org/jira/browse/CXF-1924
Project: CXF
Issue Type: Bug
Components: Core
Affects Versions: 2.1.4, 2.2
Reporter: Jarek Gawor
FileUtils.getDefaultTempDir() can go into a infinite loop when the
"java.io.tmpdir" system property is set to an non-existent directory. Here's
the code that causes the problem:
s = System.getProperty("java.io.tmpdir");
File f = new File(s, "cxf-tmp-" + x);
while (!f.mkdir()) {
x = (int)(Math.random() * 1000000);
f = new File(s, "cxf-tmp-" + x);
}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.