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

Add WebP roundtrip fuzzing target #2201

Merged
merged 1 commit into from Apr 11, 2024

Conversation

Shnatsel
Copy link
Contributor

This will detect issues such as #2171, as well as instances of incorrect encoding or decoding.

It is currently limited to RGBA, since I didn't find an easy way to use RGB format conditionally. The decoding always returns RGBA, which makes comparisons of the data a little tricky.

@fintelia
Copy link
Contributor

Looks good to me.

Though I'll note that this actually wouldn't have caught the linked issue. That was caused by a bug in the encoder that caused it to write slightly corrupt images that were missing a trailing padding byte at the end of the file. The reason it slipped through was that out decoder isn't that disciplined about ensuring that extra padding bytes are present if there's enough input data to decode all the pixels

@fintelia fintelia merged commit 779c293 into image-rs:main Apr 11, 2024
31 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants