diff --git a/README.md b/README.md index e00313f..092b69c 100644 --- a/README.md +++ b/README.md @@ -243,7 +243,7 @@ const zipped = fflate.zipSync({ 'dir1': { 'nested': { // You can use Unicode in filenames - '你好.txt': std('Hey there!') + '你好.txt': strToU8('Hey there!') }, // You can also manually write out a directory path 'other/tmp.txt': new Uint8Array([97, 98, 99, 100]) @@ -275,7 +275,7 @@ const zipped = fflate.zipSync({ // |-> other // | |-> tmp.txt // myImageData.bmp -// superTinyFile.bin +// superTinyFile.png // When decompressing, folders are not nested; all filepaths are fully // written out in the keys. For example, the return value may be: diff --git a/src/index.ts b/src/index.ts index 6fb8013..af8f36e 100644 --- a/src/index.ts +++ b/src/index.ts @@ -761,7 +761,7 @@ const adler = (): CRCV => { p(d) { // closures have awful performance let n = a, m = b; - const l = d.length; + const l = d.length | 0; for (let i = 0; i != l;) { const e = Math.min(i + 2655, l); for (; i < e; ++i) m += n += d[i];