LibCompress: Don't assume zlib header is available right away

Instead of checking the header in ZlibDecompressor::create(), we now
check it in read_some() when it is called for the first time. This
resolves a FIXME in the new DecompressionStream implementation.
This commit is contained in:
Valtteri Koskivuori 2024-11-18 20:16:55 +02:00 committed by Tim Flynn
commit 135daeb8bb
Notes: github-actions[bot] 2024-11-19 00:56:46 +00:00
6 changed files with 45 additions and 24 deletions

View file

@ -2,8 +2,7 @@
<script>
asyncTest(async done => {
const data = [
// FIXME: Enable this case when our DecompressionStream is functioning with the zlib format.
// { format: "deflate", text: "eJwLT83JUchIzcnJV0grykzNSylWBABGEQb1" },
{ format: "deflate", text: "eJwLT83JUchIzcnJV0grykzNSylWBABGEQb1" },
{ format: "deflate-raw", text: "C0/NyVHISM3JyVdIK8pMzUspVgQA" },
{ format: "gzip", text: "H4sIAAAAAAADAwtPzclRyEjNyclXSCvKTM1LKVYEAHN0w4sTAAAA" },
];