Move ifaddrs up a level on BSD

This commit is contained in:
Alex Crichton 2015-09-18 16:27:10 -07:00
parent 6603ca0d7e
commit 3715e831f8
4 changed files with 10 additions and 30 deletions

View File

@ -54,16 +54,6 @@ s! {
pub ai_next: *mut addrinfo, pub ai_next: *mut addrinfo,
} }
pub struct ifaddrs {
pub ifa_next: *mut ifaddrs,
pub ifa_name: *mut c_char,
pub ifa_flags: c_uint,
pub ifa_addr: *mut ::sockaddr,
pub ifa_netmask: *mut ::sockaddr,
pub ifa_dstaddr: *mut ::sockaddr,
pub ifa_data: *mut ::c_void
}
pub struct mach_timebase_info { pub struct mach_timebase_info {
pub numer: u32, pub numer: u32,
pub denom: u32, pub denom: u32,

View File

@ -51,16 +51,6 @@ s! {
pub ai_next: *mut addrinfo, pub ai_next: *mut addrinfo,
} }
pub struct ifaddrs {
pub ifa_next: *mut ifaddrs,
pub ifa_name: *mut ::c_char,
pub ifa_flags: ::c_uint,
pub ifa_addr: *mut ::sockaddr,
pub ifa_netmask: *mut ::sockaddr,
pub ifa_dstaddr: *mut ::sockaddr,
pub ifa_data: *mut ::c_void
}
pub struct sigset_t { pub struct sigset_t {
bits: [u32; 4], bits: [u32; 4],
} }

View File

@ -52,6 +52,16 @@ s! {
#[cfg(not(target_os = "macos"))] #[cfg(not(target_os = "macos"))]
pub pw_fields: ::c_int, pub pw_fields: ::c_int,
} }
pub struct ifaddrs {
pub ifa_next: *mut ifaddrs,
pub ifa_name: *mut ::c_char,
pub ifa_flags: ::c_uint,
pub ifa_addr: *mut ::sockaddr,
pub ifa_netmask: *mut ::sockaddr,
pub ifa_dstaddr: *mut ::sockaddr,
pub ifa_data: *mut ::c_void
}
} }
pub const FIOCLEX: c_ulong = 0x20006601; pub const FIOCLEX: c_ulong = 0x20006601;

View File

@ -65,16 +65,6 @@ s! {
pub ai_next: *mut addrinfo, pub ai_next: *mut addrinfo,
} }
pub struct ifaddrs {
pub ifa_next: *mut ifaddrs,
pub ifa_name: *mut c_char,
pub ifa_flags: c_uint,
pub ifa_addr: *mut sockaddr,
pub ifa_netmask: *mut sockaddr,
pub ifa_dstaddr: *mut sockaddr,
pub ifa_data: *mut c_void
}
pub struct stat { pub struct stat {
pub st_mode: mode_t, pub st_mode: mode_t,
pub st_dev: dev_t, pub st_dev: dev_t,