diff --git a/src/java/net/i2p/i2pfirefox/I2PCommonBrowser.java b/src/java/net/i2p/i2pfirefox/I2PCommonBrowser.java index fbf1933..62a75cf 100644 --- a/src/java/net/i2p/i2pfirefox/I2PCommonBrowser.java +++ b/src/java/net/i2p/i2pfirefox/I2PCommonBrowser.java @@ -608,11 +608,16 @@ public class I2PCommonBrowser { } public File userHomeDir() { - File hd = new File(System.getProperty("user.dir")); - if (hd == null || !hd.exists()) { - hd = new File(System.getProperty("user.home")); + File rd = new File(System.getProperty("user.dir")); + File hd = new File(System.getProperty("user.home")); + if (rd == null || !rd.exists()) { + if (hd == null || !hd.exists()) { + if (rd.getAbsolutePath().equals(hd.getAbsolutePath())) + return null; + } + return rd; } - logger.info("Runtime directory discovered at: " + hd); - return hd; + logger.info("Runtime directory discovered at: " + rd); + return rd; } }