This project is read-only.

File stream is not always closed in case of wrong password specified


SevenZipExtractor does not always close the extracted file in case wrong password is specified. I have noticed this issue extracting all files from password protected archives with one small and one big file inside.

I think the bottleneck is in the method ArchiveExtractCallback.SetOperationResult which closes the file stream in case of successful extraction but should close it also in case of any error.

Please find attached an example archive to reproduce the problem:
  1. Call ExtractAll function specifying empty directory for the result.
  2. Try to delete that directory using Windows Explorer.

file attachments