michaeljmarshall commented on code in PR #13032:
URL: https://github.com/apache/kafka/pull/13032#discussion_r1054547725


##########
clients/src/main/java/org/apache/kafka/common/protocol/DataOutputStreamWritable.java:
##########
@@ -99,7 +99,7 @@ public void writeUnsignedVarint(int i) {
     public void writeByteBuffer(ByteBuffer buf) {
         try {
             if (buf.hasArray()) {
-                out.write(buf.array(), buf.position(), buf.limit());
+                out.write(buf.array(), buf.arrayOffset(), buf.limit());

Review Comment:
   Great catch, thank you for your reviews. I'll fix the implementation and 
make sure the missed cases are covered by tests.



-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to