-
-
Notifications
You must be signed in to change notification settings - Fork 884
V3 Nested sub ifds parsing fix #2913
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
Conversation
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.
Pull Request Overview
This PR addresses the nested sub-IFDs parsing fix for JPEG metadata by introducing new tests to verify correct parsing and updating the underlying EXIF reader logic.
- Added a new test case for issue 2857 in the JPEG test suite.
- Updated ExifReader logic to process nested sub-IFDs with batch limits and improved duplicate checking.
Reviewed Changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.
File | Description |
---|---|
tests/ImageSharp.Tests/TestImages.cs | Added constant for test image issue 2857. |
tests/ImageSharp.Tests/Formats/Jpg/JpegDecoderTests.Metadata.cs | Introduced new test method for validating sub-IFDs parsing along with various EXIF metadata assertions. |
src/ImageSharp/Metadata/Profiles/Exif/ExifReader.cs | Modified sub-ifd reading loop with batch processing and adjusted duplicate comparison logic. |
Files not reviewed (1)
- tests/Images/Input/Jpg/issues/issue-2857-subsub-ifds.jpg: Language not supported
Comments suppressed due to low confidence (1)
src/ImageSharp/Metadata/Profiles/Exif/ExifReader.cs:198
- [nitpick] Consider renaming variable 'sz' to 'batchSize' for improved clarity.
int sz = Math.Min(this.subIfds.Count, maxSubIfds);
Prerequisites
Description
Reimplement of #2869 for v3.