pan3793 commented on code in PR #8526:
URL: https://github.com/apache/hadoop/pull/8526#discussion_r3338609412


##########
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/compress/zstd/ZStandardCompressor.java:
##########
@@ -301,7 +301,7 @@ public void reset() {
     finished = false;
     bytesRead = 0;
     bytesWritten = 0;
-    uncompressedDirectBuf.rewind();
+    uncompressedDirectBuf.clear();

Review Comment:
   a defensive change, I don't think `rewind`(means only reset `position` but 
not `limit`) causes any problems, but we'd better call `clear` to gain correct 
semantics.



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