Skip to content

Commit

Permalink
[JENKINS-42934] Need to catch a different exception
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenc committed Mar 20, 2017
1 parent f0cd7ae commit a7fc570
Showing 1 changed file with 2 additions and 1 deletion.
Expand Up @@ -29,6 +29,7 @@
import java.io.IOException;
import java.io.OutputStream;
import java.nio.file.Files;
import java.nio.file.NoSuchFileException;
import java.nio.file.StandardOpenOption;
import org.apache.commons.io.FileUtils;

Expand All @@ -54,7 +55,7 @@ private synchronized OutputStream current() throws IOException {
FileUtils.forceMkdir(out.getParentFile());
try {
current = Files.newOutputStream(out.toPath(), StandardOpenOption.TRUNCATE_EXISTING);
} catch (FileNotFoundException e) {
} catch (FileNotFoundException | NoSuchFileException e) {
throw new IOException("Failed to open "+out,e);
}
}
Expand Down

0 comments on commit a7fc570

Please sign in to comment.