Skip to content

Commit 857a3d1

Browse files
committed
Reduce vertical whitespace
1 parent aa93d6b commit 857a3d1

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

src/main/java/org/apache/commons/io/IOUtils.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2710,27 +2710,21 @@ public static byte[] toByteArray(final InputStream input, final long size) throw
27102710
* @throws IllegalArgumentException if {@code size} is less than zero.
27112711
*/
27122712
static byte[] toByteArray(final IOTriFunction<byte[], Integer, Integer, Integer> input, final int size) throws IOException {
2713-
27142713
if (size < 0) {
27152714
throw new IllegalArgumentException("Size must be equal or greater than zero: " + size);
27162715
}
2717-
27182716
if (size == 0) {
27192717
return EMPTY_BYTE_ARRAY;
27202718
}
2721-
27222719
final byte[] data = byteArray(size);
27232720
int offset = 0;
27242721
int read;
2725-
27262722
while (offset < size && (read = input.apply(data, offset, size - offset)) != EOF) {
27272723
offset += read;
27282724
}
2729-
27302725
if (offset != size) {
27312726
throw new IOException("Unexpected read size, current: " + offset + ", expected: " + size);
27322727
}
2733-
27342728
return data;
27352729
}
27362730

0 commit comments

Comments
 (0)