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

Fix DecoderCollection discarding input from non-seekable Readers #2878

Merged

Conversation

russellhaering
Copy link
Contributor

@russellhaering russellhaering commented May 16, 2024

This fixes a bug where a DecoderCollection would inadvertently consume from the input stream it was given while iterating through candidate formats, unless it was passed an io.ReadSeeker.

This doesn't seem to currently affect the CLI.

Signed-off-by: Russell Haering <russellhaering@gmail.com>
@russellhaering russellhaering force-pushed the russell_h/fix_decoder_collection_seeking branch from 4456290 to c0380ce Compare May 16, 2024 18:52
Copy link
Contributor

@kzantow kzantow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks @russellhaering !

@kzantow kzantow merged commit 1bec1fc into anchore:main May 16, 2024
11 checks passed
@wagoodman wagoodman added the bug Something isn't working label May 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants