Skip to content

Commit

Permalink
Stop creation of temporary directory prior to creating temporary file. (
Browse files Browse the repository at this point in the history
  • Loading branch information
dpapworth authored and rnorth committed Sep 16, 2017
1 parent ecb3286 commit 76ef418
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,8 @@ private void copyFromJarToLocation(final JarFile jarFile,

if (!entry.isDirectory()) {
// Create parent directories
newFile.mkdirs();
newFile.delete();
Path parent = newFile.getAbsoluteFile().toPath().getParent();
parent.toFile().mkdirs();
newFile.deleteOnExit();

try (InputStream is = jarFile.getInputStream(entry)) {
Expand Down

0 comments on commit 76ef418

Please sign in to comment.