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

Update README.md with an example that uses the stream API to extract an in-memory archive #336

Merged
merged 4 commits into from
Feb 15, 2024

Conversation

bytesiz3d
Copy link
Contributor

This PR adds a simple function that opens an in-memory archive in readonly mode. It also adds an additional test that verifies its operation.

@kuba--
Copy link
Owner

kuba-- commented Feb 14, 2024

Thanks for PR. We already have API to work with in-memory archive (_stream functions). For instance look at: zip_stream_openwitherror

@kuba-- kuba-- added the duplicate This issue or pull request already exists label Feb 14, 2024
@bytesiz3d
Copy link
Contributor Author

Can these functions be used to read from an in-memory zip archive? The README made me believe they were only used for writing new archives in-memory.

@bytesiz3d
Copy link
Contributor Author

Can these functions be used to read from an in-memory zip archive? The README made me believe they were only used for writing new archives in-memory.

I now see that the stream API can be used to read from an in-memory zip archive. I apologize for the confusion. I reverted my changes and added a small example to the README. I can also add one to the test cases.

README.md Outdated Show resolved Hide resolved
@bytesiz3d bytesiz3d changed the title Update zip.c and zip.h with new functions for reading in-memory zip archives Update README.md with an example that uses the stream API to extract an in-memory archive Feb 15, 2024
@kuba-- kuba-- merged commit 358a929 into kuba--:master Feb 15, 2024
4 checks passed
@bytesiz3d bytesiz3d deleted the open-in-mem branch February 16, 2024 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants