fixed incorrect uncompressed size in zip

This commit is contained in:
Danny Coates 2019-03-16 09:18:59 -07:00
parent 0e81ef2514
commit 7f13d4d9b6
No known key found for this signature in database
GPG Key ID: 4C442633C62E00CB
1 changed files with 2 additions and 2 deletions

View File

@ -50,7 +50,7 @@ class File {
v.setUint32(0, 0x08074b50, true); // sig
v.setUint32(4, this.crc, true); // crc32
v.setUint32(8, this.size, true); // compressed size
v.setUint16(12, this.size, true); // uncompressed size
v.setUint32(12, this.size, true); // uncompressed size
return new Uint8Array(dd);
}
@ -60,7 +60,7 @@ class File {
v.setUint32(0, 0x02014b50, true); // sig
v.setUint16(4, 20, true); // version made
v.setUint16(6, 20, true); // version required
v.setUint16(8, 0, true); // bit flags
v.setUint16(8, 8, true); // bit flags (8 = use data descriptor)
v.setUint16(10, 0, true); // compression
v.setUint16(12, this.dateTime.time, true); // modified time
v.setUint16(14, this.dateTime.date, true); // modified date