-
Notifications
You must be signed in to change notification settings - Fork 353
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
Some direct memory accesses lack bounds-checks #1007
Comments
So is the goal to make these methods private? Or rename to |
Making them private would be great. |
I can do a PR with the changes after rust-lang/rust#65621 lands |
The |
Hahaha yes i know about that one :P. I was talking about |
Status update: While at it, I think you can now also avoid the |
The
Allocation
APIs should generally be avoided as they are low-level building blocks and don't do bounds or alignment checks themselves. I did an audit and noticed some uses crept in recently that are not properly checked:getcwd
read
write
This can lead to ICEs. When these are fixed, a test should be added.
Cc @christianpoveda @oli-obk
It would be even better if we could stop exposing
Memory::get
andMemory::get_mut
fromlibrustc_mir
... once these issues are fixed and the current wave of PRs is in (I suggested to @christianpoveda to add awrite_bytes
API anyway), we could try to make a concerted effort to remove the remaining uses in Miri.The text was updated successfully, but these errors were encountered: