joshelser commented on code in PR #4414:
URL: https://github.com/apache/hbase/pull/4414#discussion_r869794629


##########
hbase-common/src/main/java/org/apache/hadoop/hbase/io/util/BlockIOUtils.java:
##########
@@ -284,6 +311,10 @@ private static boolean preadWithExtraDirectly(ByteBuff 
buff, FSDataInputStream d
         throw e;
       }
       if (ret < 0) {
+        if (remain <= extraLen) {
+          // break for the "extra data" when hitting end of stream and 
remaining is necessary
+          break;

Review Comment:
   That's a fair point -- I would have expected that we were very explicit and 
did exactly what the caller said. I think you did the right thing. May be good 
to capture that in a comment :)



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

Reply via email to