Skip to content

Conversation

@cmb69
Copy link
Member

@cmb69 cmb69 commented Nov 26, 2021

Since we're going to read from the current stream position anyway, the
max_len should be the size of the file minus the current position
(still catering to potentially filtered streams). We must, however,
make sure to cater to the file position being beyond the actual file
size.

While we're at, we also fix the step size in the comment, which is 8K.

A further optimization could be done for unfiltered streams, thus
saving that step size, but 8K might not be worth it.

Since we're going to read from the current stream position anyway, the
`max_len` should be the size of the file minus the current position
(still catering to potentially filtered streams).  We must, however,
make sure to cater to the file position being beyond the actual file
size.

While we're at, we also fix the step size in the comment, which is 8K.

A further optimization could be done for unfiltered streams, thus
saving that step size, but 8K might not be worth it.
@cmb69 cmb69 added the Bug label Nov 26, 2021
@cmb69 cmb69 closed this in 31749aa Nov 29, 2021
@cmb69 cmb69 deleted the cmb/81659 branch November 29, 2021 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants