kineapps / flutter_archive

Flutter plugin for creating and extracting ZIP files.
https://pub.dev/packages/flutter_archive
BSD 3-Clause "New" or "Revised" License
59 stars 44 forks source link

Android: Invalid CEN header (duplicate entry). Zip extraction failed when extract large zip > 3.7GB. #65

Closed ms-biztech closed 1 year ago

ms-biztech commented 1 year ago

Using this plugin to extract large size zip (>3.7GB) Zip contains the only image files.

Error:
PlatformException(unzip_error, invalid CEN header (duplicate entry), java.util.zip.ZipException: invalid CEN header (duplicate entry), null) W/System.err( 6189): java.util.zip.ZipException: invalid CEN header (duplicate entry)

Other android application properly extracting same zip file. I'm trying to fix this error from last two week but i'm not able to fix it. Can you please do urgent help @kinex , Thank you!

kinex commented 1 year ago

I don't think this is related to ZIP file size. There is some other problem in your zip file (error "invalid CEN header (duplicate entry)"). It could be possible to handle the error in the plugin gracefully. Can you create a small sample ZIP file having this issue? Please make a PR if possible.

ms-biztech commented 1 year ago

Thank you @kinex for quick response. Issue was in my zip file. My zip file has duplicate files with same name with the different extensions. So, i have remove duplicate files and issue is solved.