From ebf094bb46fc6e93d0bd63fbdf5ed0abe4a66977 Mon Sep 17 00:00:00 2001 From: shellrow <81893184+shellrow@users.noreply.github.com> Date: Thu, 23 Mar 2023 22:38:22 +0900 Subject: [PATCH] Correction after merge --- src/interface/unix.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/interface/unix.rs b/src/interface/unix.rs index 6cf4ff6..aa5a01b 100644 --- a/src/interface/unix.rs +++ b/src/interface/unix.rs @@ -4,8 +4,6 @@ use crate::gateway; use crate::interface::InterfaceType; use crate::ip::{Ipv4Net, Ipv6Net}; use crate::sys; - -use crate::interface::InterfaceType; use libc; use std::ffi::{CStr, CString}; use std::mem::{self, MaybeUninit}; @@ -316,7 +314,7 @@ fn unix_interfaces_inner( addr = addr_ref.ifa_next; } unsafe { - libc::freeifaddrs(addrs); + freeifaddrs(addrs); } for iface in &mut ifaces { let name = CString::new(iface.name.as_bytes()).unwrap();