Open jtmoon79 opened 1 month ago
Follow on from #291
By default, .lz4
files compressed by lz4c
do not include a content_size
.
$ lz4c --help
*** LZ4 command line interface 64-bits v1.9.3, by Yann Collet ***
Usage :
lz4c [arg] [input] [output]
...
--content-size : compressed frame includes original size (default:not present)
So even if I could access content_size
in the FrameHeader
, it would most often not be valid. So the current implementation of first reading the entire file would still be required.
Summary
The entire
.lz4
file is uncompressed to get it's uncompressed size before processing.Current behavior
Crate
lz4_flex
does not provide an API for getting the.lz4
file uncompressed size. See https://github.com/PSeitz/lz4_flex/issues/159 So the entire file is uncompressed to get the uncompressed file size.Suggested behavior
One or both
lz4_flex
.blockreader
(and all readers) to not need a file size (difficult)