mirror of
https://github.com/claunia/plist-cil.git
synced 2026-02-04 05:34:41 +00:00
[PR #10] [MERGED] Fix issues with 0-length streams #43
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/claunia/plist-cil/pull/10
Author: @qmfrederik
Created: 5/24/2016
Status: ✅ Merged
Merged: 6/22/2016
Merged by: @claunia
Base:
master← Head:fixes/0-length-stream📝 Commits (1)
12418b7Fix issue when handling 0-length streams.📊 Changes
3 files changed (+25 additions, -9 deletions)
View changed files
➕
plist-cil.test/PropertyListParserTests.cs(+20 -0)📝
plist-cil.test/plist-cil.test.csproj(+1 -0)📝
plist-cil/PropertyListParser.cs(+4 -9)📄 Description
When parsing a stream, it can happen that the stream is 0-length (or, more likely, that you're at the end of the stream by accident).
This would cause an index out of range exception in the
PropertyListParser. This PR fixes that and also optimizes how ReadAll is implemented.Hope it helps!
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.