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

dealloc_buffer_aligned leads to UB in safe code #17

Open
dtolnay opened this issue Sep 30, 2021 · 1 comment
Open

dealloc_buffer_aligned leads to UB in safe code #17

dtolnay opened this issue Sep 30, 2021 · 1 comment

Comments

@dtolnay
Copy link

dtolnay commented Sep 30, 2021

fn main() {
    aeron_rs::utils::misc::dealloc_buffer_aligned(0xdeadbeefusize as _, 100);
}
Segmentation fault (core dumped)

In general it is unsound for a safe API to result in UB.

@denisxor
Copy link
Collaborator

Can you propose the solution? May be you could do the fix and present is as PR? That will be very helpful!

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

2 participants