Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[JENKINS-42934] When you specify options you need to include CREATE o…
…r the file will not be created
  • Loading branch information
stephenc committed Mar 20, 2017
1 parent a7fc570 commit 211bb29
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -54,7 +54,7 @@ private synchronized OutputStream current() throws IOException {
if (!closed) {
FileUtils.forceMkdir(out.getParentFile());
try {
current = Files.newOutputStream(out.toPath(), StandardOpenOption.TRUNCATE_EXISTING);
current = Files.newOutputStream(out.toPath(), StandardOpenOption.CREATE, StandardOpenOption.TRUNCATE_EXISTING);
} catch (FileNotFoundException | NoSuchFileException e) {
throw new IOException("Failed to open "+out,e);
}
Expand Down

0 comments on commit 211bb29

Please sign in to comment.