[Schmitzm-commits] r119 - trunk/src/schmitzm/io

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Sat May 16 16:33:54 CEST 2009


Author: alfonx
Date: 2009-05-16 16:33:54 +0200 (Sat, 16 May 2009)
New Revision: 119

Modified:
   trunk/src/schmitzm/io/IOUtil.java
Log:
* New method: public static File getTempDir()

Modified: trunk/src/schmitzm/io/IOUtil.java
===================================================================
--- trunk/src/schmitzm/io/IOUtil.java	2009-05-16 14:33:11 UTC (rev 118)
+++ trunk/src/schmitzm/io/IOUtil.java	2009-05-16 14:33:54 UTC (rev 119)
@@ -530,7 +530,7 @@
 			String tempPath = System.getProperty("java.io.tmpdir", System
 					.getenv("TEMP"));
 
-			if (tempPath == null) {
+			if (tempPath == null || tempPath.isEmpty() || !new File(tempPath).exists()) {
 				LOGGER.warn("Temporary directory can't be found. Using /tmp");
 				tempPath = "/tmp";
 			}



More information about the Schmitzm-commits mailing list