Calling block::compress::compress_into_with_dict, with a dict of length of 1,2, or 3 results in a panic at
thread 'block::compress_slow::tests::test_all_the_stuff' panicked at 'range end index 4 out of range for slice of length 3', src/block/compress.rs:43:24
...
lz4_flex::block::compress::get_batch
at ./src/block/compress.rs:43:24
I ran into this during testing for new functionality I needed- adding a no-hash-table compressor for use in embedded/memory constrained environments. I removed the offending tests / this isn't affecting me, but it's probably still worth reporting.
Thanks for the report. The minimum match length is 4, a dict smaller than that cannot have matches. It shouldn't panic though and ignore the dict instead.
Calling
block::compress::compress_into_with_dict
, with a dict of length of 1,2, or 3 results in a panic atI ran into this during testing for new functionality I needed- adding a no-hash-table compressor for use in embedded/memory constrained environments. I removed the offending tests / this isn't affecting me, but it's probably still worth reporting.