Skip to content

Commit 6e8e3a7

Browse files
author
Federico Fissore
committed
Falling back to "user.dir" in case "APP_DIR" is missing
1 parent 199d069 commit 6e8e3a7

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

arduino-core/src/processing/app/BaseNoGui.java

+5-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,11 @@ static public PreferencesMap getBoardPreferences() {
186186
}
187187

188188
static public File getContentFile(String name) {
189-
File installationFolder = new File(System.getProperty("APP_DIR"));
189+
String appDir = System.getProperty("APP_DIR");
190+
if (appDir == null || appDir.length() == 0) {
191+
appDir = currentDirectory;
192+
}
193+
File installationFolder = new File(appDir);
190194
return new File(installationFolder, name);
191195
}
192196

0 commit comments

Comments
 (0)