summaryrefslogtreecommitdiff
path: root/qadevOOo/runner/util/utils.java
diff options
context:
space:
mode:
authorsb <sb@openoffice.org>2010-02-19 16:01:04 +0100
committersb <sb@openoffice.org>2010-02-19 16:01:04 +0100
commit5bf30beb87fe471dc055148d49c5034a105c650e (patch)
tree4392a1f8bdebd66b94a114c97724841f6ece92eb /qadevOOo/runner/util/utils.java
parentaa4295d6356f375c7b1ab7820bed9aaf762f58bb (diff)
sb118: various improvement/cleanup of qadevOOo code
Diffstat (limited to 'qadevOOo/runner/util/utils.java')
-rw-r--r--qadevOOo/runner/util/utils.java17
1 files changed, 7 insertions, 10 deletions
diff --git a/qadevOOo/runner/util/utils.java b/qadevOOo/runner/util/utils.java
index d555452ff4ee..138c771590ea 100644
--- a/qadevOOo/runner/util/utils.java
+++ b/qadevOOo/runner/util/utils.java
@@ -41,6 +41,8 @@ import java.util.ArrayList;
import java.io.RandomAccessFile;
import java.net.Socket;
import java.net.ServerSocket;
+import java.net.URI;
+import java.net.URISyntaxException;
import com.sun.star.beans.XPropertySet;
import com.sun.star.beans.Property;
@@ -367,18 +369,13 @@ public class utils {
*
*/
public static String getOfficeTemp(XMultiServiceFactory msf) {
- String tmpDir = util.utils.getUsersTempDir();
+ String url = getOfficeUserPath(msf) + "/test-temp/";
try {
- String tmp = (String) getOfficeSettingsValue(msf, "Temp");
- if (!tmp.endsWith(System.getProperty("file.separator"))) {
- tmp += System.getProperty("file.separator");
- }
- tmpDir = getFullURL(tmp);
- } catch (Exception e) {
- System.out.println("Couldn't get Office TEMP");
- e.printStackTrace();
+ new File(new URI(url)).mkdir();
+ } catch (URISyntaxException e) {
+ throw new RuntimeException(e);
}
- return tmpDir;
+ return url;
}
/**