Skip to content

Commit

Permalink
Do not try to forget a ptr
Browse files Browse the repository at this point in the history
  • Loading branch information
lu-zero committed Feb 28, 2024
1 parent 4f2e614 commit 2ea300d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions vpx-sys/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ include!(concat!(env!("OUT_DIR"), "/vpx.rs"));
mod tests {
use super::*;
use std::ffi::CStr;
use std::mem::{self, MaybeUninit};
use std::mem::MaybeUninit;
#[test]
fn version() {
println!("{}", unsafe {
Expand All @@ -32,7 +32,7 @@ mod tests {
if ret.is_null() {
panic!("Image allocation failed");
}
mem::forget(ret); // raw and ret are the same

print!("{:#?}", raw);

let mut cfg = MaybeUninit::uninit();
Expand Down

0 comments on commit 2ea300d

Please sign in to comment.