SharpZipLib icon indicating copy to clipboard operation
SharpZipLib copied to clipboard

Problem with wrong zip header error may be optional

Open mkysoft opened this issue 9 years ago • 0 comments

Some zip compress app making wrong header, for example zip4j. So SharpZipLib throwing "Size mismatch: " error at Zip\ZipInputStream.cs line 620. // A csize of -1 is from an unpatched local header if ((flags & 8) == 0 && (inf.TotalIn != csize && csize != 0xFFFFFFFF && csize != -1 || inf.TotalOut != size)) { throw new ZipException("Size mismatch: " + csize + ";" + size + " <-> " + inf.TotalIn + ";" + inf.TotalOut); }

Can we make bypass option for some errors in future versions?

mkysoft avatar Nov 26 '15 10:11 mkysoft