Fix FileLocator path separator
File.separator is the separator used in subdirectory paths ('/'), whereas File.pathSeparator is used in $PATH for separating multiple paths (':'). Using the wrong separator worked on OS X since the /var/folders subdir could be created (":ss-cache") but failed on (Linux?) ci.md-5.net since /tmp:ss-cache cannot be created (nor it should it be). With this change, the path should be /tmp/ss-cache, as expected.
This commit is contained in:
parent
dbdfa68975
commit
66b7fb9269
@ -41,7 +41,7 @@ public class FileLocator {
|
||||
|
||||
private static File download(String url) throws IOException {
|
||||
// Create temporary dir in system location
|
||||
File tempDir = new File(System.getProperty("java.io.tmpdir") + File.pathSeparator + "ss-cache");
|
||||
File tempDir = new File(System.getProperty("java.io.tmpdir") + File.separator + "ss-cache");
|
||||
if (!tempDir.exists()) {
|
||||
tempDir.mkdirs();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user