You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2007/12/14 22:13:28 UTC

svn commit: r604296 - /incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/helpers/FileUtils.java

Author: dkulp
Date: Fri Dec 14 13:13:27 2007
New Revision: 604296

URL: http://svn.apache.org/viewvc?rev=604296&view=rev
Log:
[CXF-1290] Patch from Ian Roberts applied.  Thanks!


Modified:
    incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/helpers/FileUtils.java

Modified: incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/helpers/FileUtils.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/helpers/FileUtils.java?rev=604296&r1=604295&r2=604296&view=diff
==============================================================================
--- incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/helpers/FileUtils.java (original)
+++ incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/helpers/FileUtils.java Fri Dec 14 13:13:27 2007
@@ -44,7 +44,13 @@
         if (defaultTempDir != null) {
             return defaultTempDir;
         }
-        String s = System.getProperty(FileUtils.class.getName() + ".TempDirectory");
+        
+        String s = null;
+        try {
+            s = System.getProperty(FileUtils.class.getName() + ".TempDirectory");
+        } catch (SecurityException e) {
+            //Ignorable, we'll use the default
+        }
         if (s == null) {
             int x = (int)(Math.random() * 1000000);
             s = System.getProperty("java.io.tmpdir");