yakovsh commented on code in PR #442:
URL: https://github.com/apache/commons-compress/pull/442#discussion_r1402701318
##########
src/main/java/org/apache/commons/compress/archivers/dump/TapeInputStream.java:
##########
@@ -294,6 +294,9 @@ public void resetBlockSize(final int recsPerBlock, final
boolean isCompressed) t
throw new IOException("Block with " + recsPerBlock + " records
found, must be at least 1");
}
blockSize = RECORD_SIZE * recsPerBlock;
+ if (blockSize < 1) {
+ throw new IOException("Block size " + blockSize + " cannot be
negative");
Review Comment:
I will fix this, zeros should be invalid as well
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]