We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
As we known, we can use into_raw to transfer ownership of a string to a C caller. But we also need use from_raw to retake pointer to free memory.
into_raw/from_raw is a pair, but I only find into_raw in source code, and can not find from_raw. Failure to call from_raw will lead to a memory leak.
https://doc.rust-lang.org/std/ffi/struct.CString.html#method.into_raw
The text was updated successfully, but these errors were encountered:
No branches or pull requests
As we known, we can use into_raw to transfer ownership of a string to a C caller. But we also need use from_raw to retake pointer to free memory.
into_raw/from_raw is a pair, but I only find into_raw in source code, and can not find from_raw. Failure to call from_raw will lead to a memory leak.
https://doc.rust-lang.org/std/ffi/struct.CString.html#method.into_raw
The text was updated successfully, but these errors were encountered: