Fix types and fix build + clippy lints for linux

This commit changes `copy_if_name` to take a c_char.
This commit is contained in:
dav 2023-04-12 19:30:03 -07:00 committed by Conrad Kramer
parent 47f1312666
commit 02efa85a19
3 changed files with 8 additions and 6 deletions

View file

@ -38,7 +38,7 @@ impl TunInterface {
}
pub fn name(&self) -> Result<String> {
let mut buf = [0u8; libc::IFNAMSIZ];
let mut buf = [0i8; libc::IFNAMSIZ];
let mut len = buf.len() as libc::socklen_t;
syscall!(getsockopt(
self.as_raw_fd(),