jiridanek commented on a change in pull request #1:
URL: https://github.com/apache/qpid-protonj2/pull/1#discussion_r695178881



##########
File path: 
protonj2/src/main/java/org/apache/qpid/protonj2/codec/encoders/AbstractDescribedMapTypeEncoder.java
##########
@@ -156,8 +156,8 @@ public void writeArray(ProtonBuffer buffer, EncoderState 
state, Object[] values)
         // Move back and write the size
         final int writeSize = buffer.getWriteIndex() - startIndex - 
Integer.BYTES;
 
-        if (writeSize > Integer.MAX_VALUE) {
-            throw new IllegalArgumentException("Cannot encode given array, 
encoded size to large: " + writeSize);
+        if (writeSize > Integer.MAX_VALUE) {  // same, always false

Review comment:
       Makes sense, thanks, I was thinking that you maybe meant to use long 
there right away... Ok, I'm leaving this as it is.




-- 
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]

Reply via email to