Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Calling Close or Dispose on zip entry stream, and finalizers #44

Open
dgrunwald opened this issue Dec 29, 2013 · 0 comments
Open

Calling Close or Dispose on zip entry stream, and finalizers #44

dgrunwald opened this issue Dec 29, 2013 · 0 comments
Assignees
Labels

Comments

@dgrunwald
Copy link
Member

SD-1880, originally created on 1/27/2012 05:55:20 by David Pierson

Several posters have reported issues when calling Flush Close and
Dispose on the stream they get from GetInputStream.

Worth remarking for any readers, it is recommended not to call any of
those methods against the entry stream.

Threads:
System.ObjectDisposedException: Cannot access a closed
file

http://community.sharpdevelop.net/forums/t/14397.aspx

Even without calling Close/Dispose the .NET GC may finalise the outer
stream while still using the entry stream. Believe this has been fixed
in 0.85.5 - worth desk checking.
Thread:
Random bug while
unzipping

"There is a flaw in the dispose method of ZipFile also which isnt
checking for disposing before closing streams. The f
inalizer for ZipFile can indeed be removed as Daniel states.  There is
nothing for it to do once you correct the flaw above."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants