Skip to content

Commit 2a0d02e

Browse files
committed
m
1 parent 596037a commit 2a0d02e

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

app/src/main/java/brut/androlib/res/AndrolibResources.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -994,6 +994,17 @@ public File getFrameworkDir() throws AndrolibException {
994994
} else {
995995
path = parentPath.getAbsolutePath() + String.format("%1$s.local%1$sshare%1$sapktool%1$sframework", File.separatorChar);
996996
}
997+
998+
File fullPath = new File(path);
999+
1000+
if (! fullPath.canWrite()) {
1001+
LOGGER.severe(String.format("WARNING: Could not write to (%1$s), using %2$s instead...",
1002+
fullPath.getAbsolutePath(), System.getProperty("java.io.tmpdir")));
1003+
LOGGER.severe("Please be aware this is a volatile directory and frameworks could go missing, " +
1004+
"please utilize --frame-path if the default storage directory is unavailable");
1005+
1006+
path = new File(System.getProperty("java.io.tmpdir")).getAbsolutePath();
1007+
}
9971008
}
9981009

9991010
File dir = new File(path);

0 commit comments

Comments
 (0)