arturobernalg commented on a change in pull request #326:
URL:
https://github.com/apache/httpcomponents-client/pull/326#discussion_r752658689
##########
File path:
httpclient5-cache/src/test/java/org/apache/hc/client5/http/impl/cache/HttpByteArrayCacheEntrySerializerTestUtils.java
##########
@@ -320,9 +321,7 @@ private static int readFully(final InputStream src, final
byte[] dest) throws IO
* number of bytes have been read
*/
static byte[] readFullyStrict(final InputStream src, final long length)
throws IOException {
- if (length > Integer.MAX_VALUE) {
- throw new IllegalArgumentException(String.format("Length %d is too
large to fit in an array", length));
- }
+ Args.check(length <= Integer.MAX_VALUE, String.format("Length %d is
too large to fit in an array", length));
Review comment:
HI @carterkozak thank you for the review, I really appreciate it.
I din“t see that. My bad.
sorry guys.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]