Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix build lifetime issue on freebsd, netbsd,
illumos and solaris, too warning: getting the inner pointer of a temporary `CString` --> src/bpf.rs:82:57 | 82 | CString::new(&b"/dev/bpf"[..]).unwrap().as_ptr(), | --------------------------------------- ^^^^^^ this pointer will be invalid | | | this `CString` is deallocated at the end of the statement, bind it to a variable to extend its lifetime | = note: `#[warn(temporary_cstring_as_ptr)]` on by default = note: pointers do not have a lifetime; when calling `as_ptr` the `CString` will be deallocated at the end of the statement because nothing is referencing it as far as the type system is concerned = help: for more information, see https://doc.rust-lang.org/reference/destructors.html
- Loading branch information