Comment #0 by moonlightsentinel — 2020-01-21T18:40:11Z
Test case for a truncated zip file:
unittest
{
enum data = "\x50\x4b\x01\x02\x50\x4b\x05\x06\x00\x00\x00\x00\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00";
scope zip = new ZipArchive(cast(void[]) data);
}
This causes a range error at std.zip.d:1335
Comment #1 by dlang-bot — 2020-01-24T13:21:13Z
@berni44 created dlang/phobos pull request #7365 "Fix Issue 20523 - std.zip: Invalid data yields RangeError in ZipArchive constructor" fixing this issue:
- Fix Issue 20523 - std.zip: Invalid data yields RangeError in
ZipArchive constructor
https://github.com/dlang/phobos/pull/7365
Comment #2 by robert.schadek — 2024-12-01T16:36:13Z