Skip to content

Commit

Permalink
use current dir instead of jar path
Browse files Browse the repository at this point in the history
  • Loading branch information
androidlover5842 committed May 7, 2018
1 parent 9f29672 commit 58c9ed2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/com/github/twrpbuilder/Interface/Tools.java
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ public void extract(String name) {

int readBytes;
byte[] buffer = new byte[4096];
jarFolder = new File(Tools.class.getProtectionDomain().getCodeSource().getLocation().toURI().getPath()).getParentFile().getPath().replace('\\', '/');
jarFolder = System.getProperty("user.dir");
resStreamOut = new FileOutputStream(jarFolder + resourceName);
while ((readBytes = stream.read(buffer)) > 0) {
resStreamOut.write(buffer, 0, readBytes);
Expand Down

0 comments on commit 58c9ed2

Please sign in to comment.