-
Notifications
You must be signed in to change notification settings - Fork 14
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
fix for "malfunction when reading CZIs with empty attachment-directory via curl_http_inputstream" #99
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #99 +/- ##
==========================================
+ Coverage 65.97% 65.99% +0.01%
==========================================
Files 85 85
Lines 10647 10653 +6
==========================================
+ Hits 7024 7030 +6
Misses 3623 3623
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What I understood makes sense to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks for providing this fix so fast!
Co-authored-by: m-aXimilian <56168660+m-aXimilian@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me! Approved with a couple of questions and recommendations
Description
With a CZI containing an attachment-directory-segment with zero entries, we called into the stream-object reading 0 bytes. The curl_http_inputstream object happened to throw an exception for a read-request of zero length.
The expected behavior is now documented, the curl_http_inputstream object does now tolerate a read-request for zero bytes, and where this zero-bytes-read-request was issued, it is now checked if there actually is something to be read.
Fixes #98
Type of change
How Has This Been Tested?
locally (with a CZI-document triggering this malfunction)
Checklist: