]> git.ipfire.org Git - thirdparty/zstd.git/commit
Reject dictionaries with incomplete entropy tables
authorNick Terrell <terrelln@fb.com>
Thu, 20 Oct 2016 00:22:08 +0000 (17:22 -0700)
committerNick Terrell <terrelln@fb.com>
Mon, 24 Oct 2016 17:42:44 +0000 (10:42 -0700)
commitf9c9af3c2e84bb61841ff41aa8e5afbd2ca83d7d
tree879df37fc9bd607edd114555db31bb7ef5de3856
parentd760529a058e38bb7a24b5be31060d4b2a020f6f
Reject dictionaries with incomplete entropy tables

If a dictionary specifies that a symbol has probability zero in its
`matchLength`, `literalLength`, or `offset` FSE table, but the symbol
appears when compressing input, the compressor fails.

Ensure that dictionaries support all `matchLength`, and `literalLength`
codes.  They must also support all of the `offset` codes required to
represent every possible offset that can appear in the first block.
lib/compress/zstd_compress.c