Skip to content

Commit

Permalink
Minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
marigostra committed Jan 8, 2022
1 parent 10ff6f6 commit 199accb
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -219,8 +219,7 @@ private void copySingleFile(Path fromFile, Path toFile) throws IOException
try (final InputStream in = Files.newInputStream(fromFile)) {
try (final OutputStream out = Files.newOutputStream(toFile)) {
StreamUtils.copyAllBytes(in, out,
(chunkNumBytes, totalNumBytes)->onNewChunk(chunkNumBytes),
()->{ return interrupted; });
(chunkNumBytes, totalNumBytes)->onNewChunk(chunkNumBytes), ()->interrupted);
out.flush();
if (interrupted)
throw new IOException("INTERRUPTED");
Expand Down

0 comments on commit 199accb

Please sign in to comment.