You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
flate2::Decompress::decompress is documented as "consuming only as much input as needed and writing as much output as possible". However in my tests it consumes the whole input even if output buffer size is not sufficient. Because of this I cannot use flate2 to decode the IMAP stream incrementally using async-compression crate: async-email/async-imap#112
Here is a failing test where output buffer is only 8 bytes long, but the whole input is consumed:
Here miniz_oxide::inflate::stream::inflate returns bytes_consumed equal to the whole input size even though there was not enough space in the output buffer:
I thought about reporting the bug directly to miniz_oxide, but don't see in its documentation any guarantee that it will consume only as much as needed.
The text was updated successfully, but these errors were encountered:
flate2::Decompress::decompress
is documented as "consuming only as much input as needed and writing as much output as possible". However in my tests it consumes the whole input even if output buffer size is not sufficient. Because of this I cannot useflate2
to decode the IMAP stream incrementally usingasync-compression
crate: async-email/async-imap#112Here is a failing test where output buffer is only 8 bytes long, but the whole input is consumed:
Here
miniz_oxide::inflate::stream::inflate
returnsbytes_consumed
equal to the whole input size even though there was not enough space in the output buffer:flate2-rs/src/ffi/rust.rs
Line 73 in 1a28821
I thought about reporting the bug directly to
miniz_oxide
, but don't see in its documentation any guarantee that it will consume only as much as needed.The text was updated successfully, but these errors were encountered: