ladybird/Userland/Libraries/LibCompress
Tommy Murphy 0ee98c69c1 LibCompress: Brotli support metadata of skip_length=0
The relevant RFC section from
https://www.rfc-editor.org/rfc/rfc7932#section-9.2

MSKIPBYTES * 8 bits: MSKIPLEN - 1, where MSKIPLEN is
       the number of metadata bytes; this field is
       only present if MSKIPBYTES is positive;
       otherwise, MSKIPLEN is 0 (if MSKIPBYTES is
       greater than 1, and the last byte is all
       zeros, then the stream should be rejected as
       invalid)

So when skip_bytes is zero we need to break and
re-align bytes.

Added the relevant test case that demonstrates this from:
https://github.com/google/brotli/blob/master/tests/testdata/x.compressed
2022-10-11 22:49:33 -06:00
..
Brotli.cpp LibCompress: Brotli support metadata of skip_length=0 2022-10-11 22:49:33 -06:00
Brotli.h LibCompress: Implement Brotli decompressor 2022-05-21 22:41:40 +02:00
BrotliDictionary.cpp AK+Userland: Replace Linux, macOS, and *BSD macros with platform defines 2022-10-10 12:23:12 +02:00
BrotliDictionary.h LibCompress: Implement Brotli decompressor 2022-05-21 22:41:40 +02:00
BrotliDictionaryData.bin LibCompress: Implement Brotli decompressor 2022-05-21 22:41:40 +02:00
CMakeLists.txt LibCompress: Implement Brotli decompressor 2022-05-21 22:41:40 +02:00
Deflate.cpp LibCompress: Change DeflateSpecialCodeLengths to constexpr variables 2022-04-03 17:36:48 +01:00
Deflate.h LibCompress: Change DeflateSpecialCodeLengths to constexpr variables 2022-04-03 17:36:48 +01:00
DeflateTables.h LibCompress: Add missing header to DeflateTables.h 2021-10-06 23:52:40 +01:00
Gzip.cpp Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
Gzip.h Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
Zlib.cpp LibCompress: Write Deflate window size in the Zlib header 2022-07-10 13:52:18 +03:00
Zlib.h LibCompress: Implement a Zlib compressor 2022-06-30 12:26:49 +01:00