Corrupted files extracted from PPMd ZIP archive
Opened this issue · 9 comments
It seems that some files will get corrupted when unpacking a zip archive with PPMd compression method.
import 'package:archive/archive_io.dart';
final inputStream = InputFileStream('test.zip');
final archive = ZipDecoder().decodeBuffer(inputStream);
main() => extractArchiveToDisk(archive, 'test');
I did just fix a bug in extractFileToDisk 3.3.9, I wonder if it would fix this issue.
I tried 53e1773 and it produces similar corrupted result. Also similar results with LZMA and BZip2.
Thanks for the confirmation. I'll take a look.
Looking more closely at what your question was, I realize it's about PPMd compression. Unfortunately I don't have a PPMd decompressor.
You can use 7zip client for that
I mean the library doesn't have PPMd decompression code.
I mean the library doesn't have PPMd decompression code.
In that case perhaps the file signature should be checked to avoid corrupted data.
I'll see if I can add error checking for that.
In 3.4.2 it will throw an exception if you try to decompress an unsupported compression type, including PPMd.