Writing an empty file

Jan 3, 2008 at 10:01 PM
WinZip 9.0 cannot extract empty files added with ZipFile.AddFile. WinZip displays a message box that says, "Error: invalid compressed data to inflate." If I add an empty fiel with WinZip it works fine. Has anyone else encountered this problem?
Jan 7, 2008 at 7:56 AM

I have the same problem!! I have tried to add several empty files to my created Zipfile by the routine called: Zipfile.AddFile. This executes without error messages, but when I extract the zipfile I will get an error message saying: "Unexpected End of File". Can anyone help me to solve this problem as soon as possible??
Jan 8, 2008 at 12:54 PM
I'll have to look into it. Never saw this problem, but I understand what you've described.
Jan 9, 2008 at 8:26 AM

thank you for your quick reply! Can you solve this problem? If you can solve this problem, when will you have the solution? I'm working on a project that requires zipping empty files. This project has already reached its deadline. So if you can't find a solution within 2 days, I have to find another component that does support my requirements.
Jan 10, 2008 at 9:53 AM
I have the same trouble. Let us know when you think we can expect bugfix.
Jan 10, 2008 at 2:17 PM

Hi Cheeso,

Thanks for looking into this. I'm not on a real tight deadline, but if you think this might take a while, please let me know so I can look for an alternative. Thanks.
Jan 30, 2008 at 10:08 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.
Jan 30, 2008 at 10:13 PM
Hey I don't have a copy of WinZip 9.0. Does the problem occur in Windows Explorer? on, let's say, Vista?
Jan 30, 2008 at 11:42 PM
FYI: The same problem occurs in Windows Explorer. Opening a zipfile , created by this library, and containing a zero-length file, causes an error.
Jan 31, 2008 at 12:15 AM
This is fixed in changeset 14399.
Jan 31, 2008 at 12:34 AM

Yes, the problem occurs in Windows Explorer for me. I don't have access to a Vista system. Thanks for fixing that so quickly. Unfortunately my deadline was moved up so I had to switch to SharpZipLib last week.
Jan 31, 2008 at 2:18 PM
too bad, Bill. Thanks for reporting it anyway. Maybe someone else will benefit from it.