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

Dangling pointer used in open_in_context() in the impl of UsbProperties #25

Open
quitbug opened this issue Jan 18, 2025 · 0 comments · May be fixed by #26
Open

Dangling pointer used in open_in_context() in the impl of UsbProperties #25

quitbug opened this issue Jan 18, 2025 · 0 comments · May be fixed by #26

Comments

@quitbug
Copy link

quitbug commented Jan 18, 2025

Hi, I hv noticed that there are two dangling pointers used in the function https://github.com/tanriol/ftdi-rs/blob/master/src/opener.rs#L45C8-L45C23. https://github.com/tanriol/ftdi-rs/blob/master/src/opener.rs#L45C8-L45C23 will generate two dangling pointers passed in ffi::ftdi_usb_open_desc_index(), which may result in a later Use-After-Free bug.

@quitbug quitbug linked a pull request Jan 18, 2025 that will close this issue
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 a pull request may close this issue.

1 participant