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 buffer overrun in dcd_musb driver #1227

Merged
merged 1 commit into from
Dec 5, 2021

Conversation

kkitayam
Copy link
Collaborator

@kkitayam kkitayam commented Dec 3, 2021

Describe the PR
Fix the bug of buffer overrun at pipe_read_packet() in dcd_musb.c.

Additional context
Cast operations for the left side symbols were wrong. So, when packet length is not 4 bytes unit, it occurs buffer overrun and corrupts some buffers.

Copy link
Owner

@hathach hathach left a comment

Choose a reason for hiding this comment

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

Great, thank you for your PR.

@hathach hathach merged commit f8288be into hathach:master Dec 5, 2021
@kkitayam kkitayam deleted the fix_dcd_musb_buffer_overrun branch December 7, 2021 12:46
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.

2 participants