Closed kvirund closed 2 years ago
Thanks for reporting - we'll take a look
Thank you for reporting this. I have reproduced and fixed the problem in our internal preview version, and the fix is out for code review. I'll let you know when we are releasing the fix publicly.
We're preparing to release this bugfix on April 26, 2022. Thank you for your patience.
Hi @kvirund , we have just released version 3.3.1.0.3.3
to GitHub, and the Maven Central release is making progress.
I'll close this issue, because I'm confident that the bug you reported has been fixed. If not, please feel free to re-open the issue. Thank you.
I am getting error when I am using read-ahead mode:
Here is the minimal reproducible test:
where
I am not sure if there is some logic I am not aware of but it looks like the bug is here:
Whenever we read byte-by-byte, the
data
buffer is being filled only once: whendataPos == -1
. After that nobody checks if the buffer has to be refilled.I would suggest the following fix:
Here are the last lines with
DEBUG
output enabled on theBmcReadAheadFSInputStream
:I.e. it attempted to read behind the file limits: