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

Illegal usage of memcpy when copied data is copied into itself #97

Open
benjamin-weiss opened this issue Jan 8, 2025 · 0 comments
Open

Comments

@benjamin-weiss
Copy link
Contributor

libmpegh copies USAC payload data between internally allocated buffers that under (un)certain circumstances may point to the same memory i.e. the data is being copied into itself. C standard explicitly states that memcpy() copying data between overlapping objects is undefined and thus it triggers warnings in various debugging tools. memmove() should be used instead in such circumstances.

Here is a patch to fix the issue: 0001-Use-memmove-instead-of-memcpy-since-both-pointers-ma.PATCH

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

No branches or pull requests

1 participant