From 1e368694beb896824ff3aaf5fa27e7f84f6272cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Win=E2=80=AE8201=E2=80=ADLinux=E2=80=AC?= Date: Wed, 1 Jan 2025 02:19:48 +0900 Subject: [PATCH] =?UTF-8?q?=E4=BE=9D=E5=AD=98=E9=96=A2=E4=BF=82=E3=82=92?= =?UTF-8?q?=E3=82=A2=E3=83=83=E3=83=97=E3=83=87=E3=83=BC=E3=83=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- local_proxy/Cargo.toml | 6 +- local_proxy/src/outbound/layer/tls.rs | 10 +- tproxy_tokio/Cargo.toml | 8 +- tproxy_tokio/src/lib.rs | 131 +- tproxy_tokio/src/tcp/bsd/mod.rs | 35 +- tproxy_tokio/src/tcp/bsd/pf.rs | 469 +- .../src/tcp/bsd/pfvar_bindgen_freebsd.rs | 19862 +++++++++++++ .../src/tcp/bsd/pfvar_bindgen_macos.rs | 23530 ++++++++++++++++ .../src/tcp/bsd/pfvar_bindgen_openbsd.rs | 13966 +++++++++ tproxy_tokio/src/tcp/linux/bind.rs | 11 +- tproxy_tokio/src/tcp/linux/destination.rs | 2 +- tproxy_tokio/src/tcp/linux/mod.rs | 7 +- tproxy_tokio/src/tcp/mod.rs | 12 +- tproxy_tokio/src/tcp/other.rs | 4 +- 14 files changed, 57813 insertions(+), 240 deletions(-) create mode 100644 tproxy_tokio/src/tcp/bsd/pfvar_bindgen_freebsd.rs create mode 100644 tproxy_tokio/src/tcp/bsd/pfvar_bindgen_macos.rs create mode 100644 tproxy_tokio/src/tcp/bsd/pfvar_bindgen_openbsd.rs diff --git a/local_proxy/Cargo.toml b/local_proxy/Cargo.toml index 2143824..0197690 100755 --- a/local_proxy/Cargo.toml +++ b/local_proxy/Cargo.toml @@ -13,10 +13,10 @@ hyper = { version = "1", features = ["full"] } http-body-util = "0.1" hyper-util = { version = "0.1", features = ["full"] } once_cell = "1" -base64 = "0.21" +base64 = "0.22" async-trait = "0.1" -tokio-rustls = "0.24" -rustls-native-certs = "0.6" +tokio-rustls = "0.26" +rustls-native-certs = "0.8" serde = { version = "1", features = ["derive"] } json5 = "0.4" dns-parser = "0.8" diff --git a/local_proxy/src/outbound/layer/tls.rs b/local_proxy/src/outbound/layer/tls.rs index 592d66e..e947b5a 100755 --- a/local_proxy/src/outbound/layer/tls.rs +++ b/local_proxy/src/outbound/layer/tls.rs @@ -11,11 +11,10 @@ use tokio_rustls::{rustls, TlsConnector}; static CONNECTOR: Lazy = Lazy::new(|| { let mut certs = rustls::RootCertStore::empty(); for cert in rustls_native_certs::load_native_certs().unwrap() { - let _ = certs.add(&rustls::Certificate(cert.0)); + let _ = certs.add(cert); } let config = rustls::ClientConfig::builder() - .with_safe_defaults() .with_root_certificates(certs) .with_no_client_auth(); @@ -36,10 +35,7 @@ impl Layer for TlsClient { where RW: AsyncRead + AsyncWrite + Unpin + Send + 'static, { - Ok(Box::new( - CONNECTOR - .connect(addr.hostname.to_string().as_str().try_into()?, stream) - .await?, - )) + let addr = addr.hostname.to_string(); + Ok(Box::new(CONNECTOR.connect(addr.try_into()?, stream).await?)) } } diff --git a/tproxy_tokio/Cargo.toml b/tproxy_tokio/Cargo.toml index b17e952..e9cef98 100755 --- a/tproxy_tokio/Cargo.toml +++ b/tproxy_tokio/Cargo.toml @@ -6,12 +6,14 @@ edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] +log = "0.4" cfg-if = "1" async-trait = "0.1" tokio = { version = "1", features = ["full"] } +socket2 = { version = "0.5", features = ["all"] } libc = "0.2" -socket2 = "0.5" once_cell = "1" -[target.'cfg(any(target_os = "macos", target_os = "ios", target_os = "freebsd", target_os = "netbsd", target_os = "openbsd"))'.dependencies] -nix = { version = "0.27", features = ["ioctl"] } +# Just for the ioctl call macro +[target.'cfg(any(target_os = "macos", target_os = "ios", target_os = "freebsd", target_os = "openbsd"))'.dependencies] +nix = { version = "0.29", features = ["ioctl"] } diff --git a/tproxy_tokio/src/lib.rs b/tproxy_tokio/src/lib.rs index 64f5865..ccc2691 100755 --- a/tproxy_tokio/src/lib.rs +++ b/tproxy_tokio/src/lib.rs @@ -17,32 +17,38 @@ pub enum RedirType { /// For not supported platforms NotSupported, - /// For Linux-like systems' Netfilter `REDIRECT`. Only for TCP connections. - /// This is supported from Linux 2.4 Kernel. Document: - /// NOTE: Filter rule `REDIRECT` can only be applied to TCP connections. + /// For Linux-like systems' Netfilter `REDIRECT`. Only for TCP connections. + /// + /// This is supported from Linux 2.4 Kernel. Document: + /// + /// NOTE: Filter rule `REDIRECT` can only be applied to TCP connections. #[cfg(any(target_os = "linux", target_os = "android"))] Redirect, - /// For Linux-like systems' Netfilter TPROXY rule. - /// NOTE: Filter rule `TPROXY` can be applied to TCP and UDP connections. + /// For Linux-like systems' Netfilter TPROXY rule. + /// + /// NOTE: Filter rule `TPROXY` can be applied to TCP and UDP connections. #[cfg(any(target_os = "linux", target_os = "android"))] TProxy, - /// Packet Filter (pf) - /// Supported by OpenBSD 3.0+, FreeBSD 5.3+, NetBSD 3.0+, Solaris 11.3+, macOS 10.7+, iOS, QNX - /// Document: + /// Packet Filter (pf) + /// + /// Supported by OpenBSD 3.0+, FreeBSD 5.3+, NetBSD 3.0+, Solaris 11.3+, macOS 10.7+, iOS, QNX + /// + /// Document: #[cfg(any( - target_os = "openbsd", target_os = "freebsd", - target_os = "netbsd", + target_os = "openbsd", target_os = "macos", target_os = "ios" ))] PacketFilter, - /// IPFW - /// Supported by FreeBSD, macOS 10.6- (Have been removed completely on macOS 10.10) - /// Document: https://www.freebsd.org/doc/handbook/firewalls-ipfw.html + /// IPFW + /// + /// Supported by FreeBSD, macOS 10.6- (Have been removed completely on macOS 10.10) + /// + /// Document: https://www.freebsd.org/doc/handbook/firewalls-ipfw.html #[cfg(any(target_os = "freebsd", target_os = "macos", target_os = "ios"))] IpFirewall, } @@ -56,32 +62,95 @@ impl RedirType { } /// Available TCP transparent proxy types + #[doc(hidden)] pub fn tcp_available_types() -> &'static [&'static str] { const AVAILABLE_TYPES: &[&str] = &[RedirType::Redirect.name(), RedirType::TProxy.name()]; AVAILABLE_TYPES } - } else if #[cfg(any(target_os = "openbsd", target_os = "freebsd"))] { + + /// Default UDP transparent proxy solution on this platform + pub const fn udp_default() -> RedirType { + RedirType::TProxy + } + + /// Available UDP transparent proxy types + #[doc(hidden)] + pub fn udp_available_types() -> &'static [&'static str] { + const AVAILABLE_TYPES: &[&str] = &[RedirType::TProxy.name()]; + AVAILABLE_TYPES + } + } else if #[cfg(any(target_os = "freebsd"))] { /// Default TCP transparent proxy solution on this platform pub fn tcp_default() -> RedirType { RedirType::PacketFilter } /// Available TCP transparent proxy types + #[doc(hidden)] pub fn tcp_available_types() -> &'static [&'static str] { const AVAILABLE_TYPES: &[&str] = &[RedirType::PacketFilter.name(), RedirType::IpFirewall.name()]; AVAILABLE_TYPES } - } else if #[cfg(any(target_os = "netbsd", target_os = "macos", target_os = "ios"))] { + + /// Default UDP transparent proxy solution on this platform + pub fn udp_default() -> RedirType { + RedirType::PacketFilter + } + + /// Available UDP transparent proxy types + #[doc(hidden)] + pub const fn udp_available_types() -> &'static [&'static str] { + const AVAILABLE_TYPES: &[&str] = &[RedirType::PacketFilter.name(), RedirType::IpFirewall.name()]; + AVAILABLE_TYPES + } + } else if #[cfg(target_os = "openbsd")] { /// Default TCP transparent proxy solution on this platform pub fn tcp_default() -> RedirType { RedirType::PacketFilter } /// Available TCP transparent proxy types + #[doc(hidden)] + pub fn tcp_available_types() -> &'static [&'static str] { + const AVAILABLE_TYPES: &[&str] = &[RedirType::PacketFilter.name()]; + AVAILABLE_TYPES + } + + /// Default UDP transparent proxy solution on this platform + pub fn udp_default() -> RedirType { + RedirType::PacketFilter + } + + /// Available UDP transparent proxy types + #[doc(hidden)] + pub const fn udp_available_types() -> &'static [&'static str] { + const AVAILABLE_TYPES: &[&str] = &[RedirType::PacketFilter.name()]; + AVAILABLE_TYPES + } + } else if #[cfg(any(target_os = "macos", target_os = "ios"))] { + /// Default TCP transparent proxy solution on this platform + pub fn tcp_default() -> RedirType { + RedirType::PacketFilter + } + + /// Available TCP transparent proxy types + #[doc(hidden)] pub const fn tcp_available_types() -> &'static [&'static str] { const AVAILABLE_TYPES: &[&str] = &[RedirType::PacketFilter.name(), RedirType::IpFirewall.name()]; AVAILABLE_TYPES } + + /// Default UDP transparent proxy solution on this platform + pub fn udp_default() -> RedirType { + RedirType::PacketFilter + } + + /// Available UDP transparent proxy types + #[doc(hidden)] + pub const fn udp_available_types() -> &'static [&'static str] { + const AVAILABLE_TYPES: &[&str] = &[RedirType::PacketFilter.name()]; + AVAILABLE_TYPES + } } else { /// Default TCP transparent proxy solution on this platform pub fn tcp_default() -> RedirType { @@ -89,13 +158,31 @@ impl RedirType { } /// Available TCP transparent proxy types + #[doc(hidden)] pub const fn tcp_available_types() -> &'static [&'static str] { const AVAILABLE_TYPES: &[&str] = &[]; AVAILABLE_TYPES } + + /// Default UDP transparent proxy solution on this platform + pub fn udp_default() -> RedirType { + RedirType::NotSupported + } + + /// Available UDP transparent proxy types + #[doc(hidden)] + pub const fn udp_available_types() -> &'static [&'static str] { + const AVAILABLE_TYPES: &[&str] = &[]; + AVAILABLE_TYPES + } } } + /// Check if transparent proxy is supported on this platform + pub fn is_supported(self) -> bool { + self != RedirType::NotSupported + } + /// Name of redirect type (transparent proxy type) pub const fn name(self) -> &'static str { match self { @@ -109,9 +196,8 @@ impl RedirType { RedirType::TProxy => "tproxy", #[cfg(any( - target_os = "openbsd", target_os = "freebsd", - target_os = "netbsd", + target_os = "openbsd", target_os = "macos", target_os = "ios" ))] @@ -153,21 +239,14 @@ impl FromStr for RedirType { "tproxy" => Ok(RedirType::TProxy), #[cfg(any( - target_os = "openbsd", target_os = "freebsd", - target_os = "netbsd", - target_os = "solaris", + target_os = "openbsd", target_os = "macos", target_os = "ios", ))] "pf" => Ok(RedirType::PacketFilter), - #[cfg(any( - target_os = "freebsd", - target_os = "macos", - target_os = "ios", - target_os = "dragonfly" - ))] + #[cfg(any(target_os = "freebsd", target_os = "macos", target_os = "ios",))] "ipfw" => Ok(RedirType::IpFirewall), _ => Err(InvalidRedirType), diff --git a/tproxy_tokio/src/tcp/bsd/mod.rs b/tproxy_tokio/src/tcp/bsd/mod.rs index c912f33..99c8e7c 100755 --- a/tproxy_tokio/src/tcp/bsd/mod.rs +++ b/tproxy_tokio/src/tcp/bsd/mod.rs @@ -13,25 +13,24 @@ use socket2::Protocol; #[async_trait] impl TcpListenerRedirExt for TcpListener { - async fn bind_redir(ty: RedirType, addr: SocketAddr) -> Result { + async fn bind_redir(ty: RedirType, addr: SocketAddr) -> io::Result { match ty { #[cfg(any( - target_os = "openbsd", target_os = "freebsd", - target_os = "netbsd", + target_os = "openbsd", target_os = "macos", - target_os = "ios", + target_os = "ios" ))] RedirType::PacketFilter => {} - #[cfg(any(target_os = "freebsd", target_os = "macos", target_os = "ios",))] + #[cfg(any(target_os = "freebsd", target_os = "macos", target_os = "ios"))] RedirType::IpFirewall => {} _ => { return Err(Error::new( ErrorKind::InvalidInput, "not supported tcp transparent proxy type", - )) + )); } } @@ -45,30 +44,26 @@ impl TcpListenerRedirExt for TcpListener { impl TcpStreamRedirExt for TcpStream { fn destination_addr(&self, ty: RedirType) -> io::Result { match ty { - #[cfg(any( - target_os = "openbsd", - target_os = "freebsd", - target_os = "netbsd", - target_os = "macos", - target_os = "ios", - ))] - RedirType::Redirect => { + #[cfg(any(target_os = "freebsd", target_os = "macos", target_os = "ios"))] + RedirType::PacketFilter => { let peer_addr = self.peer_addr()?; let bind_addr = self.local_addr()?; pf::PF.natlook(&bind_addr, &peer_addr, Protocol::TCP) } - - #[cfg(any(target_os = "freebsd", target_os = "macos", target_os = "ios",))] + #[cfg(target_os = "openbsd")] + // in OpenBSD, we can get TCP destination address with getsockname() + RedirType::PacketFilter => self.local_addr(), + #[cfg(any(target_os = "freebsd", target_os = "macos", target_os = "ios"))] RedirType::IpFirewall => { + // ## IPFW + // // For IPFW, uses getsockname() to retrieve destination address + // // FreeBSD: https://www.freebsd.org/doc/handbook/firewalls-ipfw.html self.local_addr() } - _ => Err(Error::new( - ErrorKind::InvalidInput, - "not supported tcp transparent proxy type", - )), + _ => unreachable!("not supported tcp transparent proxy type"), } } } diff --git a/tproxy_tokio/src/tcp/bsd/pf.rs b/tproxy_tokio/src/tcp/bsd/pf.rs index 26df336..2941828 100755 --- a/tproxy_tokio/src/tcp/bsd/pf.rs +++ b/tproxy_tokio/src/tcp/bsd/pf.rs @@ -1,122 +1,43 @@ +cfg_if! { + if #[cfg(any(target_os = "macos", + target_os = "ios"))] { + #[path = "pfvar_bindgen_macos.rs"] + #[allow(dead_code, non_upper_case_globals, non_snake_case, non_camel_case_types)] + #[allow(clippy::useless_transmute, clippy::too_many_arguments, clippy::unnecessary_cast, clippy::upper_case_acronyms)] + mod pfvar; + } else if #[cfg(target_os = "freebsd")] { + #[path = "pfvar_bindgen_freebsd.rs"] + #[allow(dead_code, non_upper_case_globals, non_snake_case, non_camel_case_types)] + #[allow(clippy::useless_transmute, clippy::too_many_arguments, clippy::unnecessary_cast, clippy::upper_case_acronyms)] + mod pfvar; + } else if #[cfg(target_os = "openbsd")] { + #[path = "pfvar_bindgen_openbsd.rs"] + #[allow(dead_code, non_upper_case_globals, non_snake_case, non_camel_case_types)] + #[allow(clippy::useless_transmute, clippy::too_many_arguments, clippy::unnecessary_cast, clippy::upper_case_acronyms)] + mod pfvar; + } +} + use std::{ - ffi::CString, io::{self, Error, ErrorKind}, mem, net::SocketAddr, ptr, }; +use cfg_if::cfg_if; +use log::trace; +use nix::ioctl_readwrite; use once_cell::sync::Lazy; use socket2::{Protocol, SockAddr}; -#[allow(non_camel_case_types)] -mod ffi { - use cfg_if::cfg_if; - use nix::ioctl_readwrite; - - #[repr(C)] - #[derive(Copy, Clone)] - pub struct pf_addr { - pub pfa: pf_addr__bindgen_ty_1, - } - - #[repr(C)] - #[derive(Copy, Clone)] - pub union pf_addr__bindgen_ty_1 { - pub v4: libc::in_addr, - pub v6: libc::in6_addr, - pub addr8: [u8; 16usize], - pub addr16: [u16; 8usize], - pub addr32: [u32; 4usize], - _bindgen_union_align: [u32; 4usize], - } - - cfg_if! { - if #[cfg(any(target_os = "macos", target_os = "ios"))] { - #[repr(C)] - #[derive(Copy, Clone)] - pub union pf_state_xport { - pub port: u16, - pub call_id: u16, - pub spi: u32, - } - - // Apple's XNU customized structure - // - // https://github.com/opensource-apple/xnu/blob/master/bsd/net/pfvar.h - #[repr(C)] - #[derive(Copy, Clone)] - pub struct pfioc_natlook { - pub saddr: pf_addr, - pub daddr: pf_addr, - pub rsaddr: pf_addr, - pub rdaddr: pf_addr, - pub sxport: pf_state_xport, - pub dxport: pf_state_xport, - pub rsxport: pf_state_xport, - pub rdxport: pf_state_xport, - pub af: libc::sa_family_t, - pub proto: u8, - pub proto_variant: u8, - pub direction: u8, - } - - impl pfioc_natlook { - pub unsafe fn set_sport(&mut self, port: u16) { - self.sxport.port = port; - } - - pub unsafe fn set_dport(&mut self, port: u16) { - self.dxport.port = port; - } - - pub unsafe fn rdport(&self) -> u16 { - self.rdxport.port - } - } - - } else { - // FreeBSD's definition, should be the same as all the other platforms - // - // https://github.com/freebsd/freebsd/blob/master/sys/net/pfvar.h - #[repr(C)] - #[derive(Copy, Clone)] - pub struct pfioc_natlook { - pub saddr: pf_addr, - pub daddr: pf_addr, - pub rsaddr: pf_addr, - pub rdaddr: pf_addr, - pub sport: u16, - pub dport: u16, - pub rsport: u16, - pub rdport: u16, - pub af: libc::sa_family_t, - pub proto: u8, - pub proto_variant: u8, - pub direction: u8, - } - - impl pfioc_natlook { - pub fn set_sport(&mut self, port: u16) { - self.sport = port; - } - - pub fn set_dport(&mut self, port: u16) { - self.dport = port; - } - - pub fn rdport(&self) -> u16 { - self.rdport - } - } - } - } +use pfvar::{in6_addr, in_addr, pfioc_natlook, sockaddr_in, sockaddr_in6, PF_OUT}; +#[cfg(any(target_os = "macos", target_os = "ios"))] +use pfvar::{pf_addr, pfioc_states, pfsync_state}; - // pub const PF_IN: libc::c_int = 1; - pub const PF_OUT: libc::c_int = 2; - - ioctl_readwrite!(ioc_natlook, 'D', 23, pfioc_natlook); -} +ioctl_readwrite!(ioc_natlook, 'D', 23, pfioc_natlook); +#[cfg(any(target_os = "macos", target_os = "ios"))] +ioctl_readwrite!(ioc_getstates, 'D', 25, pfioc_states); pub struct PacketFilter { fd: libc::c_int, @@ -125,11 +46,11 @@ pub struct PacketFilter { impl PacketFilter { fn open() -> io::Result { unsafe { - let dev_path = CString::new("/dev/pf").expect("CString::new"); + let dev_path = b"/dev/pf\0"; // According to FreeBSD's doc // https://www.freebsd.org/cgi/man.cgi?query=pf&sektion=4&apropos=0&manpath=FreeBSD+12.1-RELEASE+and+Ports - let fd = libc::open(dev_path.as_ptr(), libc::O_RDONLY); + let fd = libc::open(dev_path.as_ptr() as *const _, libc::O_RDONLY); if fd < 0 { let err = Error::last_os_error(); return Err(err); @@ -157,43 +78,69 @@ impl PacketFilter { peer_addr: &SocketAddr, proto: Protocol, ) -> io::Result { + match proto { + Protocol::TCP => self.tcp_natlook(bind_addr, peer_addr, proto), + #[cfg(any(target_os = "macos", target_os = "ios"))] + Protocol::UDP => self.udp_natlook(bind_addr, peer_addr, proto), + _ => Err(io::ErrorKind::InvalidInput.into()), + } + } + + fn tcp_natlook( + &self, + bind_addr: &SocketAddr, + peer_addr: &SocketAddr, + proto: Protocol, + ) -> io::Result { + trace!("PF natlook peer: {}, bind: {}", peer_addr, bind_addr); + unsafe { - let mut pnl: ffi::pfioc_natlook = mem::zeroed(); + let mut pnl: pfioc_natlook = mem::zeroed(); match *bind_addr { SocketAddr::V4(ref v4) => { pnl.af = libc::AF_INET as libc::sa_family_t; let sockaddr = SockAddr::from(*v4); - let sockaddr = sockaddr.as_ptr() as *const libc::sockaddr_in; + let sockaddr = sockaddr.as_ptr() as *const sockaddr_in; - let addr: *const libc::in_addr = &((*sockaddr).sin_addr) as *const _; + let addr: *const in_addr = ptr::addr_of!((*sockaddr).sin_addr) as *const _; let port: libc::in_port_t = (*sockaddr).sin_port; - #[allow(clippy::size_of_in_element_count)] - ptr::copy_nonoverlapping( - addr, - &mut pnl.daddr.pfa.v4, - mem::size_of_val(&pnl.daddr.pfa.v4), + ptr::write_unaligned::( + ptr::addr_of_mut!(pnl.daddr.pfa) as *mut _, + *addr, ); - pnl.set_dport(port); + + cfg_if! { + if #[cfg(any(target_os = "macos", target_os = "ios"))] { + pnl.dxport.port = port; + } else { + pnl.dport = port; + } + } } SocketAddr::V6(ref v6) => { pnl.af = libc::AF_INET6 as libc::sa_family_t; let sockaddr = SockAddr::from(*v6); - let sockaddr = sockaddr.as_ptr() as *const libc::sockaddr_in6; + let sockaddr = sockaddr.as_ptr() as *const sockaddr_in6; - let addr: *const libc::in6_addr = &((*sockaddr).sin6_addr) as *const _; + let addr: *const in6_addr = ptr::addr_of!((*sockaddr).sin6_addr) as *const _; let port: libc::in_port_t = (*sockaddr).sin6_port; - #[allow(clippy::size_of_in_element_count)] - ptr::copy_nonoverlapping( - addr, - &mut pnl.daddr.pfa.v6, - mem::size_of_val(&pnl.daddr.pfa.v6), + ptr::write_unaligned::( + ptr::addr_of_mut!(pnl.daddr.pfa) as *mut _, + *addr, ); - pnl.set_dport(port); + + cfg_if! { + if #[cfg(any(target_os = "macos", target_os = "ios"))] { + pnl.dxport.port = port; + } else { + pnl.dport = port; + } + } } } @@ -207,18 +154,23 @@ impl PacketFilter { } let sockaddr = SockAddr::from(*v4); - let sockaddr = sockaddr.as_ptr() as *const libc::sockaddr_in; + let sockaddr = sockaddr.as_ptr() as *const sockaddr_in; - let addr: *const libc::in_addr = &((*sockaddr).sin_addr) as *const _; + let addr: *const in_addr = ptr::addr_of!((*sockaddr).sin_addr) as *const _; let port: libc::in_port_t = (*sockaddr).sin_port; - #[allow(clippy::size_of_in_element_count)] - ptr::copy_nonoverlapping( - addr, - &mut pnl.saddr.pfa.v4, - mem::size_of_val(&pnl.saddr.pfa.v4), + ptr::write_unaligned::( + ptr::addr_of_mut!(pnl.saddr.pfa) as *mut _, + *addr, ); - pnl.set_sport(port); + + cfg_if! { + if #[cfg(any(target_os = "macos", target_os = "ios"))] { + pnl.sxport.port = port; + } else { + pnl.sport = port; + } + } } SocketAddr::V6(ref v6) => { if pnl.af != libc::AF_INET6 as libc::sa_family_t { @@ -229,51 +181,68 @@ impl PacketFilter { } let sockaddr = SockAddr::from(*v6); - let sockaddr = sockaddr.as_ptr() as *const libc::sockaddr_in6; + let sockaddr = sockaddr.as_ptr() as *const sockaddr_in6; - let addr: *const libc::in6_addr = &((*sockaddr).sin6_addr) as *const _; + let addr: *const in6_addr = ptr::addr_of!((*sockaddr).sin6_addr) as *const _; let port: libc::in_port_t = (*sockaddr).sin6_port; - #[allow(clippy::size_of_in_element_count)] - ptr::copy_nonoverlapping( - addr, - &mut pnl.saddr.pfa.v6, - mem::size_of_val(&pnl.saddr.pfa.v6), + ptr::write_unaligned::( + ptr::addr_of_mut!(pnl.saddr.pfa) as *mut _, + *addr, ); - pnl.set_sport(port); + + cfg_if! { + if #[cfg(any(target_os = "macos", target_os = "ios"))] { + pnl.sxport.port = port; + } else { + pnl.sport = port; + } + } } } pnl.proto = i32::from(proto) as u8; - pnl.direction = ffi::PF_OUT as u8; + pnl.direction = PF_OUT as u8; - if let Err(err) = ffi::ioc_natlook(self.fd, &mut pnl as *mut _) { + if let Err(err) = ioc_natlook(self.fd, &mut pnl) { return Err(Error::from_raw_os_error(err as i32)); } let (_, dst_addr) = SockAddr::try_init(|dst_addr, addr_len| { if pnl.af == libc::AF_INET as libc::sa_family_t { - let dst_addr: &mut libc::sockaddr_in = &mut *(dst_addr as *mut _); + let dst_addr: &mut sockaddr_in = &mut *(dst_addr as *mut _); dst_addr.sin_family = pnl.af; - dst_addr.sin_port = pnl.rdport(); - #[allow(clippy::size_of_in_element_count)] - ptr::copy_nonoverlapping( - &pnl.rdaddr.pfa.v4, - &mut dst_addr.sin_addr, - mem::size_of_val(&pnl.rdaddr.pfa.v4), + + cfg_if! { + if #[cfg(any(target_os = "macos", target_os = "ios"))] { + dst_addr.sin_port = pnl.rdxport.port; + } else { + dst_addr.sin_port = pnl.rdport; + } + } + + ptr::write_unaligned::( + ptr::addr_of_mut!(dst_addr.sin_addr), + ptr::read::(ptr::addr_of!(pnl.rdaddr.pfa) as *const _), ); - *addr_len = mem::size_of_val(&pnl.rdaddr.pfa.v4) as libc::socklen_t; + *addr_len = mem::size_of_val(&dst_addr.sin_addr) as libc::socklen_t; } else if pnl.af == libc::AF_INET6 as libc::sa_family_t { - let dst_addr: &mut libc::sockaddr_in6 = &mut *(dst_addr as *mut _); + let dst_addr: &mut sockaddr_in6 = &mut *(dst_addr as *mut _); dst_addr.sin6_family = pnl.af; - dst_addr.sin6_port = pnl.rdport(); - #[allow(clippy::size_of_in_element_count)] - ptr::copy_nonoverlapping( - &pnl.rdaddr.pfa.v6, - &mut dst_addr.sin6_addr, - mem::size_of_val(&pnl.rdaddr.pfa.v6), + + cfg_if! { + if #[cfg(any(target_os = "macos", target_os = "ios"))] { + dst_addr.sin6_port = pnl.rdxport.port; + } else { + dst_addr.sin6_port = pnl.rdport; + } + } + + ptr::write_unaligned::( + ptr::addr_of_mut!(dst_addr.sin6_addr), + ptr::read::(ptr::addr_of!(pnl.rdaddr.pfa) as *const _), ); - *addr_len = mem::size_of_val(&pnl.rdaddr.pfa.v6) as libc::socklen_t; + *addr_len = mem::size_of_val(&dst_addr.sin6_addr) as libc::socklen_t; } else { unreachable!("sockaddr should be either ipv4 or ipv6"); } @@ -284,6 +253,184 @@ impl PacketFilter { Ok(dst_addr.as_socket().expect("SocketAddr")) } } + + #[cfg(any(target_os = "macos", target_os = "ios"))] + fn udp_natlook( + &self, + bind_addr: &SocketAddr, + peer_addr: &SocketAddr, + _proto: Protocol, + ) -> io::Result { + unsafe { + // Get all states + // https://man.freebsd.org/cgi/man.cgi?query=pf&sektion=4&manpath=OpenBSD + // DIOCGETSTATES + + let mut states: pfioc_states = mem::zeroed(); + let mut states_buffer = vec![0u8; 8192]; + + loop { + states.ps_len = states_buffer.len() as _; + states.ps_u.psu_buf = states_buffer.as_mut_ptr() as *mut _; + + if let Err(err) = ioc_getstates(self.fd, &mut states) { + return Err(Error::from_raw_os_error(err as i32)); + } + + if states.ps_len as usize <= states_buffer.len() { + break; + } + + // Resize to fit all states + // > On exit, ps_len is always set to the total size re- + // > quired to hold all state table entries + states_buffer.resize(states.ps_len as usize, 0); + } + + let bind_addr_sockaddr = SockAddr::from(*bind_addr); + let peer_addr_sockaddr = SockAddr::from(*peer_addr); + + let mut bind_addr_pfaddr: pf_addr = mem::zeroed(); + let mut peer_addr_pfaddr: pf_addr = mem::zeroed(); + + match bind_addr_sockaddr.family() as libc::c_int { + libc::AF_INET => { + let sockaddr: *const sockaddr_in = bind_addr_sockaddr.as_ptr() as *const _; + ptr::write_unaligned::( + ptr::addr_of_mut!(bind_addr_pfaddr.pfa) as *mut _, + (*sockaddr).sin_addr, + ); + } + libc::AF_INET6 => { + let sockaddr: *const sockaddr_in6 = bind_addr_sockaddr.as_ptr() as *const _; + ptr::write_unaligned::( + ptr::addr_of_mut!(bind_addr_pfaddr.pfa) as *mut _, + (*sockaddr).sin6_addr, + ); + } + _ => unreachable!("bind_addr family = {}", bind_addr_sockaddr.family()), + } + + match peer_addr_sockaddr.family() as libc::c_int { + libc::AF_INET => { + let sockaddr: *const sockaddr_in = peer_addr_sockaddr.as_ptr() as *const _; + ptr::write_unaligned::( + ptr::addr_of_mut!(peer_addr_pfaddr.pfa) as *mut _, + (*sockaddr).sin_addr, + ); + } + libc::AF_INET6 => { + let sockaddr: *const sockaddr_in6 = peer_addr_sockaddr.as_ptr() as *const _; + ptr::write_unaligned::( + ptr::addr_of_mut!(peer_addr_pfaddr.pfa) as *mut _, + (*sockaddr).sin6_addr, + ); + } + _ => unreachable!("peer_addr family = {}", peer_addr_sockaddr.family()), + } + + let states_count = states.ps_len as usize / mem::size_of::(); + for i in 0..states_count { + let state = &*(states.ps_u.psu_states.add(i)); + + if state.proto == libc::IPPROTO_UDP as u8 { + cfg_if! { + if #[cfg(any(target_os = "macos", target_os = "ios"))] { + let dst_port = state.lan.xport.port; + let src_port = state.ext_gwy.xport.port; + let actual_dst_port = state.gwy.xport.port; + } else { + let dst_port = state.lan.port; + let src_port = state.ext_gwy.port; + let actual_dst_port = state.gwy.port; + } + } + + let dst_addr_eq = libc::memcmp( + &bind_addr_pfaddr as *const _ as *const _, + ptr::addr_of!(state.lan.addr.pfa) as *const _, + mem::size_of::(), + ) == 0; + let src_addr_eq = libc::memcmp( + &peer_addr_pfaddr as *const _ as *const _, + ptr::addr_of!(state.ext_gwy.addr.pfa) as *const _, + mem::size_of::(), + ) == 0; + + if src_addr_eq + && src_port == peer_addr.port() + && dst_addr_eq + && dst_port == bind_addr.port() + { + let actual_dst_addr = match state.af_gwy as libc::c_int { + libc::AF_INET => { + let (_, actual_dst_addr) = SockAddr::try_init(|sockaddr, len| { + let addr = &mut *(sockaddr as *mut sockaddr_in); + addr.sin_family = libc::AF_INET as libc::sa_family_t; + ptr::write_unaligned::( + ptr::addr_of_mut!(addr.sin_addr), + ptr::read_unaligned::(ptr::addr_of!( + state.gwy.addr.pfa + ) + as *const _), + ); + addr.sin_port = actual_dst_port as libc::in_port_t; + + ptr::write( + len, + mem::size_of::() as libc::socklen_t, + ); + Ok(()) + }) + .unwrap(); + + actual_dst_addr + } + libc::AF_INET6 => { + let (_, actual_dst_addr) = SockAddr::try_init(|sockaddr, len| { + let addr = &mut *(sockaddr as *mut sockaddr_in6); + addr.sin6_family = libc::AF_INET6 as libc::sa_family_t; + ptr::write_unaligned::( + ptr::addr_of_mut!(addr.sin6_addr), + ptr::read_unaligned::(ptr::addr_of!( + state.gwy.addr.pfa + ) + as *const _), + ); + addr.sin6_port = actual_dst_port as libc::in_port_t; + + ptr::write( + len, + mem::size_of::() as libc::socklen_t, + ); + Ok(()) + }) + .unwrap(); + + actual_dst_addr + } + _ => { + return Err(io::Error::new( + ErrorKind::Other, + format!( + "state.af_gwy {} is not a valid address family", + state.af_gwy + ), + )); + } + }; + + return Ok(actual_dst_addr.as_socket().expect("SocketAddr")); + } + } + } + } + + Err(io::Error::new( + ErrorKind::Other, + format!("natlook UDP binding {}, {} not found", bind_addr, peer_addr), + )) + } } impl Drop for PacketFilter { diff --git a/tproxy_tokio/src/tcp/bsd/pfvar_bindgen_freebsd.rs b/tproxy_tokio/src/tcp/bsd/pfvar_bindgen_freebsd.rs new file mode 100644 index 0000000..fa900ea --- /dev/null +++ b/tproxy_tokio/src/tcp/bsd/pfvar_bindgen_freebsd.rs @@ -0,0 +1,19862 @@ +// automatically generated by rust-bindgen 0.69.2 + +pub const BSD: u32 = 199506; +pub const BSD4_3: u32 = 1; +pub const BSD4_4: u32 = 1; +pub const __FreeBSD_version: u32 = 1400097; +pub const __GNUCLIKE_ASM: u32 = 3; +pub const __GNUCLIKE___TYPEOF: u32 = 1; +pub const __GNUCLIKE___SECTION: u32 = 1; +pub const __GNUCLIKE_CTOR_SECTION_HANDLING: u32 = 1; +pub const __GNUCLIKE_BUILTIN_CONSTANT_P: u32 = 1; +pub const __GNUCLIKE_BUILTIN_VARARGS: u32 = 1; +pub const __GNUCLIKE_BUILTIN_STDARG: u32 = 1; +pub const __GNUCLIKE_BUILTIN_VAALIST: u32 = 1; +pub const __GNUC_VA_LIST_COMPATIBILITY: u32 = 1; +pub const __GNUCLIKE_BUILTIN_NEXT_ARG: u32 = 1; +pub const __GNUCLIKE_BUILTIN_MEMCPY: u32 = 1; +pub const __CC_SUPPORTS_INLINE: u32 = 1; +pub const __CC_SUPPORTS___INLINE: u32 = 1; +pub const __CC_SUPPORTS___INLINE__: u32 = 1; +pub const __CC_SUPPORTS___FUNC__: u32 = 1; +pub const __CC_SUPPORTS_WARNING: u32 = 1; +pub const __CC_SUPPORTS_VARADIC_XXX: u32 = 1; +pub const __CC_SUPPORTS_DYNAMIC_ARRAY_INIT: u32 = 1; +pub const __POSIX_VISIBLE: u32 = 200809; +pub const __XSI_VISIBLE: u32 = 700; +pub const __BSD_VISIBLE: u32 = 1; +pub const __ISO_C_VISIBLE: u32 = 2011; +pub const __EXT1_VISIBLE: u32 = 1; +pub const __CHAR_BIT: u32 = 8; +pub const __SCHAR_MAX: u32 = 127; +pub const __SCHAR_MIN: i32 = -128; +pub const __UCHAR_MAX: u32 = 255; +pub const __USHRT_MAX: u32 = 65535; +pub const __SHRT_MAX: u32 = 32767; +pub const __SHRT_MIN: i32 = -32768; +pub const __UINT_MAX: u32 = 4294967295; +pub const __INT_MAX: u32 = 2147483647; +pub const __INT_MIN: i32 = -2147483648; +pub const __ULONG_MAX: i32 = -1; +pub const __LONG_MAX: u64 = 9223372036854775807; +pub const __LONG_MIN: i64 = -9223372036854775808; +pub const __ULLONG_MAX: i32 = -1; +pub const __LLONG_MAX: u64 = 9223372036854775807; +pub const __LLONG_MIN: i64 = -9223372036854775808; +pub const __SSIZE_MAX: u64 = 9223372036854775807; +pub const __SIZE_T_MAX: i32 = -1; +pub const __OFF_MAX: u64 = 9223372036854775807; +pub const __OFF_MIN: i64 = -9223372036854775808; +pub const __UQUAD_MAX: i32 = -1; +pub const __QUAD_MAX: u64 = 9223372036854775807; +pub const __QUAD_MIN: i64 = -9223372036854775808; +pub const __LONG_BIT: u32 = 64; +pub const __WORD_BIT: u32 = 32; +pub const __MINSIGSTKSZ: u32 = 2048; +pub const __WCHAR_MIN: i32 = -2147483648; +pub const __WCHAR_MAX: u32 = 2147483647; +pub const _QUAD_HIGHWORD: u32 = 1; +pub const _QUAD_LOWWORD: u32 = 0; +pub const _SIG_WORDS: u32 = 4; +pub const _SIG_MAXSIG: u32 = 128; +pub const FD_SETSIZE: u32 = 1024; +pub const ARG_MAX: u32 = 524288; +pub const CHILD_MAX: u32 = 40; +pub const MAX_CANON: u32 = 255; +pub const MAX_INPUT: u32 = 255; +pub const NAME_MAX: u32 = 255; +pub const NGROUPS_MAX: u32 = 1023; +pub const OPEN_MAX: u32 = 64; +pub const PATH_MAX: u32 = 1024; +pub const PIPE_BUF: u32 = 512; +pub const IOV_MAX: u32 = 1024; +pub const MAXCOMLEN: u32 = 19; +pub const MAXINTERP: u32 = 1024; +pub const MAXLOGNAME: u32 = 33; +pub const MAXUPRC: u32 = 40; +pub const NCARGS: u32 = 524288; +pub const NGROUPS: u32 = 1024; +pub const NOFILE: u32 = 64; +pub const NOGROUP: u32 = 65535; +pub const MAXHOSTNAMELEN: u32 = 256; +pub const SPECNAMELEN: u32 = 255; +pub const _X86_SIGNAL_H: u32 = 1; +pub const SIGHUP: u32 = 1; +pub const SIGINT: u32 = 2; +pub const SIGQUIT: u32 = 3; +pub const SIGILL: u32 = 4; +pub const SIGTRAP: u32 = 5; +pub const SIGABRT: u32 = 6; +pub const SIGIOT: u32 = 6; +pub const SIGEMT: u32 = 7; +pub const SIGFPE: u32 = 8; +pub const SIGKILL: u32 = 9; +pub const SIGBUS: u32 = 10; +pub const SIGSEGV: u32 = 11; +pub const SIGSYS: u32 = 12; +pub const SIGPIPE: u32 = 13; +pub const SIGALRM: u32 = 14; +pub const SIGTERM: u32 = 15; +pub const SIGURG: u32 = 16; +pub const SIGSTOP: u32 = 17; +pub const SIGTSTP: u32 = 18; +pub const SIGCONT: u32 = 19; +pub const SIGCHLD: u32 = 20; +pub const SIGTTIN: u32 = 21; +pub const SIGTTOU: u32 = 22; +pub const SIGIO: u32 = 23; +pub const SIGXCPU: u32 = 24; +pub const SIGXFSZ: u32 = 25; +pub const SIGVTALRM: u32 = 26; +pub const SIGPROF: u32 = 27; +pub const SIGWINCH: u32 = 28; +pub const SIGINFO: u32 = 29; +pub const SIGUSR1: u32 = 30; +pub const SIGUSR2: u32 = 31; +pub const SIGTHR: u32 = 32; +pub const SIGLWP: u32 = 32; +pub const SIGLIBRT: u32 = 33; +pub const SIGRTMIN: u32 = 65; +pub const SIGRTMAX: u32 = 126; +pub const SIGEV_NONE: u32 = 0; +pub const SIGEV_SIGNAL: u32 = 1; +pub const SIGEV_THREAD: u32 = 2; +pub const SIGEV_KEVENT: u32 = 3; +pub const SIGEV_THREAD_ID: u32 = 4; +pub const ILL_ILLOPC: u32 = 1; +pub const ILL_ILLOPN: u32 = 2; +pub const ILL_ILLADR: u32 = 3; +pub const ILL_ILLTRP: u32 = 4; +pub const ILL_PRVOPC: u32 = 5; +pub const ILL_PRVREG: u32 = 6; +pub const ILL_COPROC: u32 = 7; +pub const ILL_BADSTK: u32 = 8; +pub const BUS_ADRALN: u32 = 1; +pub const BUS_ADRERR: u32 = 2; +pub const BUS_OBJERR: u32 = 3; +pub const BUS_OOMERR: u32 = 100; +pub const SEGV_MAPERR: u32 = 1; +pub const SEGV_ACCERR: u32 = 2; +pub const SEGV_PKUERR: u32 = 100; +pub const FPE_INTOVF: u32 = 1; +pub const FPE_INTDIV: u32 = 2; +pub const FPE_FLTDIV: u32 = 3; +pub const FPE_FLTOVF: u32 = 4; +pub const FPE_FLTUND: u32 = 5; +pub const FPE_FLTRES: u32 = 6; +pub const FPE_FLTINV: u32 = 7; +pub const FPE_FLTSUB: u32 = 8; +pub const FPE_FLTIDO: u32 = 9; +pub const TRAP_BRKPT: u32 = 1; +pub const TRAP_TRACE: u32 = 2; +pub const TRAP_DTRACE: u32 = 3; +pub const TRAP_CAP: u32 = 4; +pub const CLD_EXITED: u32 = 1; +pub const CLD_KILLED: u32 = 2; +pub const CLD_DUMPED: u32 = 3; +pub const CLD_TRAPPED: u32 = 4; +pub const CLD_STOPPED: u32 = 5; +pub const CLD_CONTINUED: u32 = 6; +pub const POLL_IN: u32 = 1; +pub const POLL_OUT: u32 = 2; +pub const POLL_MSG: u32 = 3; +pub const POLL_ERR: u32 = 4; +pub const POLL_PRI: u32 = 5; +pub const POLL_HUP: u32 = 6; +pub const SA_NOCLDSTOP: u32 = 8; +pub const SA_ONSTACK: u32 = 1; +pub const SA_RESTART: u32 = 2; +pub const SA_RESETHAND: u32 = 4; +pub const SA_NODEFER: u32 = 16; +pub const SA_NOCLDWAIT: u32 = 32; +pub const SA_SIGINFO: u32 = 64; +pub const NSIG: u32 = 32; +pub const SI_NOINFO: u32 = 0; +pub const SI_USER: u32 = 65537; +pub const SI_QUEUE: u32 = 65538; +pub const SI_TIMER: u32 = 65539; +pub const SI_ASYNCIO: u32 = 65540; +pub const SI_MESGQ: u32 = 65541; +pub const SI_KERNEL: u32 = 65542; +pub const SI_LWP: u32 = 65543; +pub const SI_UNDEFINED: u32 = 0; +pub const SS_ONSTACK: u32 = 1; +pub const SS_DISABLE: u32 = 4; +pub const MINSIGSTKSZ: u32 = 2048; +pub const SIGSTKSZ: u32 = 34816; +pub const SV_ONSTACK: u32 = 1; +pub const SV_INTERRUPT: u32 = 2; +pub const SV_RESETHAND: u32 = 4; +pub const SV_NODEFER: u32 = 16; +pub const SV_NOCLDSTOP: u32 = 8; +pub const SV_SIGINFO: u32 = 64; +pub const SIG_BLOCK: u32 = 1; +pub const SIG_UNBLOCK: u32 = 2; +pub const SIG_SETMASK: u32 = 3; +pub const MACHINE: &[u8; 6] = b"amd64\0"; +pub const MACHINE_ARCH: &[u8; 6] = b"amd64\0"; +pub const MACHINE_ARCH32: &[u8; 5] = b"i386\0"; +pub const MAXCPU: u32 = 1; +pub const MAXMEMDOM: u32 = 8; +pub const CACHE_LINE_SHIFT: u32 = 6; +pub const CACHE_LINE_SIZE: u32 = 64; +pub const NPTEPGSHIFT: u32 = 9; +pub const PAGE_SHIFT: u32 = 12; +pub const PAGE_SIZE: u32 = 4096; +pub const PAGE_MASK: u32 = 4095; +pub const NPDEPGSHIFT: u32 = 9; +pub const PDRSHIFT: u32 = 21; +pub const NBPDR: u32 = 2097152; +pub const PDRMASK: u32 = 2097151; +pub const NPDPEPGSHIFT: u32 = 9; +pub const PDPSHIFT: u32 = 30; +pub const NBPDP: u32 = 1073741824; +pub const PDPMASK: u32 = 1073741823; +pub const NPML4EPGSHIFT: u32 = 9; +pub const PML4SHIFT: u32 = 39; +pub const NBPML4: u64 = 549755813888; +pub const PML4MASK: u64 = 549755813887; +pub const NPML5EPGSHIFT: u32 = 9; +pub const PML5SHIFT: u32 = 48; +pub const NBPML5: u64 = 281474976710656; +pub const PML5MASK: u64 = 281474976710655; +pub const MAXPAGESIZES: u32 = 3; +pub const IOPAGES: u32 = 2; +pub const IOPERM_BITMAP_SIZE: u32 = 8193; +pub const KSTACK_PAGES: u32 = 4; +pub const KSTACK_GUARD_PAGES: u32 = 1; +pub const CHAR_BIT: u32 = 8; +pub const SCHAR_MAX: u32 = 127; +pub const SCHAR_MIN: i32 = -128; +pub const UCHAR_MAX: u32 = 255; +pub const CHAR_MAX: u32 = 127; +pub const CHAR_MIN: i32 = -128; +pub const USHRT_MAX: u32 = 65535; +pub const SHRT_MAX: u32 = 32767; +pub const SHRT_MIN: i32 = -32768; +pub const UINT_MAX: u32 = 4294967295; +pub const INT_MAX: u32 = 2147483647; +pub const INT_MIN: i32 = -2147483648; +pub const ULONG_MAX: i32 = -1; +pub const LONG_MAX: u64 = 9223372036854775807; +pub const LONG_MIN: i64 = -9223372036854775808; +pub const ULLONG_MAX: i32 = -1; +pub const LLONG_MAX: u64 = 9223372036854775807; +pub const LLONG_MIN: i64 = -9223372036854775808; +pub const SSIZE_MAX: u64 = 9223372036854775807; +pub const SIZE_T_MAX: i32 = -1; +pub const OFF_MAX: u64 = 9223372036854775807; +pub const OFF_MIN: i64 = -9223372036854775808; +pub const GID_MAX: u32 = 4294967295; +pub const UID_MAX: u32 = 4294967295; +pub const UQUAD_MAX: i32 = -1; +pub const QUAD_MAX: u64 = 9223372036854775807; +pub const QUAD_MIN: i64 = -9223372036854775808; +pub const LONG_BIT: u32 = 64; +pub const WORD_BIT: u32 = 32; +pub const MQ_PRIO_MAX: u32 = 64; +pub const DEV_BSHIFT: u32 = 9; +pub const DEV_BSIZE: u32 = 512; +pub const BLKDEV_IOSIZE: u32 = 4096; +pub const DFLTPHYS: u32 = 65536; +pub const MAXPHYS: u32 = 1048576; +pub const MAXDUMPPGS: u32 = 16; +pub const MSIZE: u32 = 256; +pub const MCLSHIFT: u32 = 11; +pub const MCLBYTES: u32 = 2048; +pub const MJUMPAGESIZE: u32 = 4096; +pub const MJUM9BYTES: u32 = 9216; +pub const MJUM16BYTES: u32 = 16384; +pub const PRIMASK: u32 = 255; +pub const PCATCH: u32 = 256; +pub const PDROP: u32 = 512; +pub const PNOLOCK: u32 = 1024; +pub const PRILASTFLAG: u32 = 1024; +pub const NZERO: u32 = 0; +pub const NBBY: u32 = 8; +pub const CMASK: u32 = 18; +pub const MAXBSIZE: u32 = 65536; +pub const MAXBCACHEBUF: u32 = 65536; +pub const BKVASIZE: u32 = 16384; +pub const BKVAMASK: u32 = 16383; +pub const MAXPATHLEN: u32 = 1024; +pub const MAXSYMLINKS: u32 = 32; +pub const FSHIFT: u32 = 11; +pub const FSCALE: u32 = 2048; +pub const CPU_MAXSIZE: u32 = 1024; +pub const CPU_SETSIZE: u32 = 1024; +pub const CPU_LEVEL_ROOT: u32 = 1; +pub const CPU_LEVEL_CPUSET: u32 = 2; +pub const CPU_LEVEL_WHICH: u32 = 3; +pub const CPU_WHICH_TID: u32 = 1; +pub const CPU_WHICH_PID: u32 = 2; +pub const CPU_WHICH_CPUSET: u32 = 3; +pub const CPU_WHICH_IRQ: u32 = 4; +pub const CPU_WHICH_JAIL: u32 = 5; +pub const CPU_WHICH_DOMAIN: u32 = 6; +pub const CPU_WHICH_INTRHANDLER: u32 = 7; +pub const CPU_WHICH_ITHREAD: u32 = 8; +pub const CPU_WHICH_TIDPID: u32 = 9; +pub const CPUSET_INVALID: i32 = -1; +pub const CPUSET_DEFAULT: u32 = 0; +pub const M_NOWAIT: u32 = 1; +pub const M_WAITOK: u32 = 2; +pub const M_NORECLAIM: u32 = 128; +pub const M_ZERO: u32 = 256; +pub const M_NOVM: u32 = 512; +pub const M_USE_RESERVE: u32 = 1024; +pub const M_NODUMP: u32 = 2048; +pub const M_FIRSTFIT: u32 = 4096; +pub const M_BESTFIT: u32 = 8192; +pub const M_EXEC: u32 = 16384; +pub const M_NEXTFIT: u32 = 32768; +pub const M_VERSION: u32 = 2020110501; +pub const DTMALLOC_PROBE_MALLOC: u32 = 0; +pub const DTMALLOC_PROBE_FREE: u32 = 1; +pub const DTMALLOC_PROBE_MAX: u32 = 2; +pub const MALLOC_TYPE_STREAM_VERSION: u32 = 1; +pub const MALLOC_MAX_NAME: u32 = 32; +pub const __bool_true_false_are_defined: u32 = 1; +pub const false_: u32 = 0; +pub const true_: u32 = 1; +pub const INT8_MIN: i32 = -128; +pub const INT16_MIN: i32 = -32768; +pub const INT32_MIN: i32 = -2147483648; +pub const INT8_MAX: u32 = 127; +pub const INT16_MAX: u32 = 32767; +pub const INT32_MAX: u32 = 2147483647; +pub const UINT8_MAX: u32 = 255; +pub const UINT16_MAX: u32 = 65535; +pub const UINT32_MAX: u32 = 4294967295; +pub const INT64_MIN: i64 = -9223372036854775808; +pub const INT64_MAX: u64 = 9223372036854775807; +pub const UINT64_MAX: i32 = -1; +pub const INT_LEAST8_MIN: i32 = -128; +pub const INT_LEAST16_MIN: i32 = -32768; +pub const INT_LEAST32_MIN: i32 = -2147483648; +pub const INT_LEAST64_MIN: i64 = -9223372036854775808; +pub const INT_LEAST8_MAX: u32 = 127; +pub const INT_LEAST16_MAX: u32 = 32767; +pub const INT_LEAST32_MAX: u32 = 2147483647; +pub const INT_LEAST64_MAX: u64 = 9223372036854775807; +pub const UINT_LEAST8_MAX: u32 = 255; +pub const UINT_LEAST16_MAX: u32 = 65535; +pub const UINT_LEAST32_MAX: u32 = 4294967295; +pub const UINT_LEAST64_MAX: i32 = -1; +pub const INT_FAST8_MIN: i32 = -2147483648; +pub const INT_FAST16_MIN: i32 = -2147483648; +pub const INT_FAST32_MIN: i32 = -2147483648; +pub const INT_FAST64_MIN: i64 = -9223372036854775808; +pub const INT_FAST8_MAX: u32 = 2147483647; +pub const INT_FAST16_MAX: u32 = 2147483647; +pub const INT_FAST32_MAX: u32 = 2147483647; +pub const INT_FAST64_MAX: u64 = 9223372036854775807; +pub const UINT_FAST8_MAX: u32 = 4294967295; +pub const UINT_FAST16_MAX: u32 = 4294967295; +pub const UINT_FAST32_MAX: u32 = 4294967295; +pub const UINT_FAST64_MAX: i32 = -1; +pub const INTPTR_MIN: i64 = -9223372036854775808; +pub const INTPTR_MAX: u64 = 9223372036854775807; +pub const UINTPTR_MAX: i32 = -1; +pub const INTMAX_MIN: i64 = -9223372036854775808; +pub const INTMAX_MAX: u64 = 9223372036854775807; +pub const UINTMAX_MAX: i32 = -1; +pub const PTRDIFF_MIN: i64 = -9223372036854775808; +pub const PTRDIFF_MAX: u64 = 9223372036854775807; +pub const SIG_ATOMIC_MIN: i64 = -9223372036854775808; +pub const SIG_ATOMIC_MAX: u64 = 9223372036854775807; +pub const SIZE_MAX: i32 = -1; +pub const WINT_MIN: i32 = -2147483648; +pub const WINT_MAX: u32 = 2147483647; +pub const __WORDSIZE: u32 = 64; +pub const WCHAR_MIN: i32 = -2147483648; +pub const WCHAR_MAX: u32 = 2147483647; +pub const RSIZE_MAX: i32 = -1; +pub const __SLBF: u32 = 1; +pub const __SNBF: u32 = 2; +pub const __SRD: u32 = 4; +pub const __SWR: u32 = 8; +pub const __SRW: u32 = 16; +pub const __SEOF: u32 = 32; +pub const __SERR: u32 = 64; +pub const __SMBF: u32 = 128; +pub const __SAPP: u32 = 256; +pub const __SSTR: u32 = 512; +pub const __SOPT: u32 = 1024; +pub const __SNPT: u32 = 2048; +pub const __SOFF: u32 = 4096; +pub const __SMOD: u32 = 8192; +pub const __SALC: u32 = 16384; +pub const __SIGN: u32 = 32768; +pub const __S2OAP: u32 = 1; +pub const _IOFBF: u32 = 0; +pub const _IOLBF: u32 = 1; +pub const _IONBF: u32 = 2; +pub const BUFSIZ: u32 = 1024; +pub const EOF: i32 = -1; +pub const FOPEN_MAX: u32 = 20; +pub const FILENAME_MAX: u32 = 1024; +pub const P_tmpdir: &[u8; 6] = b"/tmp/\0"; +pub const L_tmpnam: u32 = 1024; +pub const TMP_MAX: u32 = 308915776; +pub const SEEK_SET: u32 = 0; +pub const SEEK_CUR: u32 = 1; +pub const SEEK_END: u32 = 2; +pub const L_cuserid: u32 = 17; +pub const L_ctermid: u32 = 1024; +pub const NV_NAME_MAX: u32 = 2048; +pub const NV_TYPE_NONE: u32 = 0; +pub const NV_TYPE_NULL: u32 = 1; +pub const NV_TYPE_BOOL: u32 = 2; +pub const NV_TYPE_NUMBER: u32 = 3; +pub const NV_TYPE_STRING: u32 = 4; +pub const NV_TYPE_NVLIST: u32 = 5; +pub const NV_TYPE_DESCRIPTOR: u32 = 6; +pub const NV_TYPE_BINARY: u32 = 7; +pub const NV_TYPE_BOOL_ARRAY: u32 = 8; +pub const NV_TYPE_NUMBER_ARRAY: u32 = 9; +pub const NV_TYPE_STRING_ARRAY: u32 = 10; +pub const NV_TYPE_NVLIST_ARRAY: u32 = 11; +pub const NV_TYPE_DESCRIPTOR_ARRAY: u32 = 12; +pub const NV_FLAG_IGNORE_CASE: u32 = 1; +pub const NV_FLAG_NO_UNIQUE: u32 = 2; +pub const REFCOUNT_SATURATION_VALUE: u32 = 3221225472; +pub const _DTRACE_VERSION: u32 = 1; +pub const CTL_MAXNAME: u32 = 24; +pub const CTLTYPE: u32 = 15; +pub const CTLTYPE_NODE: u32 = 1; +pub const CTLTYPE_INT: u32 = 2; +pub const CTLTYPE_STRING: u32 = 3; +pub const CTLTYPE_S64: u32 = 4; +pub const CTLTYPE_OPAQUE: u32 = 5; +pub const CTLTYPE_STRUCT: u32 = 5; +pub const CTLTYPE_UINT: u32 = 6; +pub const CTLTYPE_LONG: u32 = 7; +pub const CTLTYPE_ULONG: u32 = 8; +pub const CTLTYPE_U64: u32 = 9; +pub const CTLTYPE_U8: u32 = 10; +pub const CTLTYPE_U16: u32 = 11; +pub const CTLTYPE_S8: u32 = 12; +pub const CTLTYPE_S16: u32 = 13; +pub const CTLTYPE_S32: u32 = 14; +pub const CTLTYPE_U32: u32 = 15; +pub const CTLFLAG_RD: u32 = 2147483648; +pub const CTLFLAG_WR: u32 = 1073741824; +pub const CTLFLAG_RW: u32 = 3221225472; +pub const CTLFLAG_DORMANT: u32 = 536870912; +pub const CTLFLAG_ANYBODY: u32 = 268435456; +pub const CTLFLAG_SECURE: u32 = 134217728; +pub const CTLFLAG_PRISON: u32 = 67108864; +pub const CTLFLAG_DYN: u32 = 33554432; +pub const CTLFLAG_SKIP: u32 = 16777216; +pub const CTLMASK_SECURE: u32 = 15728640; +pub const CTLFLAG_TUN: u32 = 524288; +pub const CTLFLAG_RDTUN: u32 = 2148007936; +pub const CTLFLAG_RWTUN: u32 = 3221749760; +pub const CTLFLAG_MPSAFE: u32 = 262144; +pub const CTLFLAG_VNET: u32 = 131072; +pub const CTLFLAG_DYING: u32 = 65536; +pub const CTLFLAG_CAPRD: u32 = 32768; +pub const CTLFLAG_CAPWR: u32 = 16384; +pub const CTLFLAG_STATS: u32 = 8192; +pub const CTLFLAG_NOFETCH: u32 = 4096; +pub const CTLFLAG_CAPRW: u32 = 49152; +pub const CTLFLAG_NEEDGIANT: u32 = 2048; +pub const CTLSHIFT_SECURE: u32 = 20; +pub const CTLFLAG_SECURE1: u32 = 134217728; +pub const CTLFLAG_SECURE2: u32 = 135266304; +pub const CTLFLAG_SECURE3: u32 = 136314880; +pub const OID_AUTO: i32 = -1; +pub const CTL_AUTO_START: u32 = 256; +pub const CTL_SYSCTL: u32 = 0; +pub const CTL_KERN: u32 = 1; +pub const CTL_VM: u32 = 2; +pub const CTL_VFS: u32 = 3; +pub const CTL_NET: u32 = 4; +pub const CTL_DEBUG: u32 = 5; +pub const CTL_HW: u32 = 6; +pub const CTL_MACHDEP: u32 = 7; +pub const CTL_USER: u32 = 8; +pub const CTL_P1003_1B: u32 = 9; +pub const CTL_SYSCTL_DEBUG: u32 = 0; +pub const CTL_SYSCTL_NAME: u32 = 1; +pub const CTL_SYSCTL_NEXT: u32 = 2; +pub const CTL_SYSCTL_NAME2OID: u32 = 3; +pub const CTL_SYSCTL_OIDFMT: u32 = 4; +pub const CTL_SYSCTL_OIDDESCR: u32 = 5; +pub const CTL_SYSCTL_OIDLABEL: u32 = 6; +pub const CTL_SYSCTL_NEXTNOSKIP: u32 = 7; +pub const KERN_OSTYPE: u32 = 1; +pub const KERN_OSRELEASE: u32 = 2; +pub const KERN_OSREV: u32 = 3; +pub const KERN_VERSION: u32 = 4; +pub const KERN_MAXVNODES: u32 = 5; +pub const KERN_MAXPROC: u32 = 6; +pub const KERN_MAXFILES: u32 = 7; +pub const KERN_ARGMAX: u32 = 8; +pub const KERN_SECURELVL: u32 = 9; +pub const KERN_HOSTNAME: u32 = 10; +pub const KERN_HOSTID: u32 = 11; +pub const KERN_CLOCKRATE: u32 = 12; +pub const KERN_PROC: u32 = 14; +pub const KERN_FILE: u32 = 15; +pub const KERN_PROF: u32 = 16; +pub const KERN_POSIX1: u32 = 17; +pub const KERN_NGROUPS: u32 = 18; +pub const KERN_JOB_CONTROL: u32 = 19; +pub const KERN_SAVED_IDS: u32 = 20; +pub const KERN_BOOTTIME: u32 = 21; +pub const KERN_NISDOMAINNAME: u32 = 22; +pub const KERN_UPDATEINTERVAL: u32 = 23; +pub const KERN_OSRELDATE: u32 = 24; +pub const KERN_NTP_PLL: u32 = 25; +pub const KERN_BOOTFILE: u32 = 26; +pub const KERN_MAXFILESPERPROC: u32 = 27; +pub const KERN_MAXPROCPERUID: u32 = 28; +pub const KERN_DUMPDEV: u32 = 29; +pub const KERN_IPC: u32 = 30; +pub const KERN_DUMMY: u32 = 31; +pub const KERN_PS_STRINGS: u32 = 32; +pub const KERN_USRSTACK: u32 = 33; +pub const KERN_LOGSIGEXIT: u32 = 34; +pub const KERN_IOV_MAX: u32 = 35; +pub const KERN_HOSTUUID: u32 = 36; +pub const KERN_ARND: u32 = 37; +pub const KERN_MAXPHYS: u32 = 38; +pub const KERN_LOCKF: u32 = 39; +pub const KERN_PROC_ALL: u32 = 0; +pub const KERN_PROC_PID: u32 = 1; +pub const KERN_PROC_PGRP: u32 = 2; +pub const KERN_PROC_SESSION: u32 = 3; +pub const KERN_PROC_TTY: u32 = 4; +pub const KERN_PROC_UID: u32 = 5; +pub const KERN_PROC_RUID: u32 = 6; +pub const KERN_PROC_ARGS: u32 = 7; +pub const KERN_PROC_PROC: u32 = 8; +pub const KERN_PROC_SV_NAME: u32 = 9; +pub const KERN_PROC_RGID: u32 = 10; +pub const KERN_PROC_GID: u32 = 11; +pub const KERN_PROC_PATHNAME: u32 = 12; +pub const KERN_PROC_OVMMAP: u32 = 13; +pub const KERN_PROC_OFILEDESC: u32 = 14; +pub const KERN_PROC_KSTACK: u32 = 15; +pub const KERN_PROC_INC_THREAD: u32 = 16; +pub const KERN_PROC_VMMAP: u32 = 32; +pub const KERN_PROC_FILEDESC: u32 = 33; +pub const KERN_PROC_GROUPS: u32 = 34; +pub const KERN_PROC_ENV: u32 = 35; +pub const KERN_PROC_AUXV: u32 = 36; +pub const KERN_PROC_RLIMIT: u32 = 37; +pub const KERN_PROC_PS_STRINGS: u32 = 38; +pub const KERN_PROC_UMASK: u32 = 39; +pub const KERN_PROC_OSREL: u32 = 40; +pub const KERN_PROC_SIGTRAMP: u32 = 41; +pub const KERN_PROC_CWD: u32 = 42; +pub const KERN_PROC_NFDS: u32 = 43; +pub const KERN_PROC_SIGFASTBLK: u32 = 44; +pub const KERN_PROC_VM_LAYOUT: u32 = 45; +pub const KIPC_MAXSOCKBUF: u32 = 1; +pub const KIPC_SOCKBUF_WASTE: u32 = 2; +pub const KIPC_SOMAXCONN: u32 = 3; +pub const KIPC_MAX_LINKHDR: u32 = 4; +pub const KIPC_MAX_PROTOHDR: u32 = 5; +pub const KIPC_MAX_HDR: u32 = 6; +pub const KIPC_MAX_DATALEN: u32 = 7; +pub const HW_MACHINE: u32 = 1; +pub const HW_MODEL: u32 = 2; +pub const HW_NCPU: u32 = 3; +pub const HW_BYTEORDER: u32 = 4; +pub const HW_PHYSMEM: u32 = 5; +pub const HW_USERMEM: u32 = 6; +pub const HW_PAGESIZE: u32 = 7; +pub const HW_DISKNAMES: u32 = 8; +pub const HW_DISKSTATS: u32 = 9; +pub const HW_FLOATINGPT: u32 = 10; +pub const HW_MACHINE_ARCH: u32 = 11; +pub const HW_REALMEM: u32 = 12; +pub const USER_CS_PATH: u32 = 1; +pub const USER_BC_BASE_MAX: u32 = 2; +pub const USER_BC_DIM_MAX: u32 = 3; +pub const USER_BC_SCALE_MAX: u32 = 4; +pub const USER_BC_STRING_MAX: u32 = 5; +pub const USER_COLL_WEIGHTS_MAX: u32 = 6; +pub const USER_EXPR_NEST_MAX: u32 = 7; +pub const USER_LINE_MAX: u32 = 8; +pub const USER_RE_DUP_MAX: u32 = 9; +pub const USER_POSIX2_VERSION: u32 = 10; +pub const USER_POSIX2_C_BIND: u32 = 11; +pub const USER_POSIX2_C_DEV: u32 = 12; +pub const USER_POSIX2_CHAR_TERM: u32 = 13; +pub const USER_POSIX2_FORT_DEV: u32 = 14; +pub const USER_POSIX2_FORT_RUN: u32 = 15; +pub const USER_POSIX2_LOCALEDEF: u32 = 16; +pub const USER_POSIX2_SW_DEV: u32 = 17; +pub const USER_POSIX2_UPE: u32 = 18; +pub const USER_STREAM_MAX: u32 = 19; +pub const USER_TZNAME_MAX: u32 = 20; +pub const USER_LOCALBASE: u32 = 21; +pub const CTL_P1003_1B_ASYNCHRONOUS_IO: u32 = 1; +pub const CTL_P1003_1B_MAPPED_FILES: u32 = 2; +pub const CTL_P1003_1B_MEMLOCK: u32 = 3; +pub const CTL_P1003_1B_MEMLOCK_RANGE: u32 = 4; +pub const CTL_P1003_1B_MEMORY_PROTECTION: u32 = 5; +pub const CTL_P1003_1B_MESSAGE_PASSING: u32 = 6; +pub const CTL_P1003_1B_PRIORITIZED_IO: u32 = 7; +pub const CTL_P1003_1B_PRIORITY_SCHEDULING: u32 = 8; +pub const CTL_P1003_1B_REALTIME_SIGNALS: u32 = 9; +pub const CTL_P1003_1B_SEMAPHORES: u32 = 10; +pub const CTL_P1003_1B_FSYNC: u32 = 11; +pub const CTL_P1003_1B_SHARED_MEMORY_OBJECTS: u32 = 12; +pub const CTL_P1003_1B_SYNCHRONIZED_IO: u32 = 13; +pub const CTL_P1003_1B_TIMERS: u32 = 14; +pub const CTL_P1003_1B_AIO_LISTIO_MAX: u32 = 15; +pub const CTL_P1003_1B_AIO_MAX: u32 = 16; +pub const CTL_P1003_1B_AIO_PRIO_DELTA_MAX: u32 = 17; +pub const CTL_P1003_1B_DELAYTIMER_MAX: u32 = 18; +pub const CTL_P1003_1B_MQ_OPEN_MAX: u32 = 19; +pub const CTL_P1003_1B_PAGESIZE: u32 = 20; +pub const CTL_P1003_1B_RTSIG_MAX: u32 = 21; +pub const CTL_P1003_1B_SEM_NSEMS_MAX: u32 = 22; +pub const CTL_P1003_1B_SEM_VALUE_MAX: u32 = 23; +pub const CTL_P1003_1B_SIGQUEUE_MAX: u32 = 24; +pub const CTL_P1003_1B_TIMER_MAX: u32 = 25; +pub const KTR_GEN: u32 = 1; +pub const KTR_NET: u32 = 2; +pub const KTR_DEV: u32 = 4; +pub const KTR_LOCK: u32 = 8; +pub const KTR_SMP: u32 = 16; +pub const KTR_SUBSYS: u32 = 32; +pub const KTR_PMAP: u32 = 64; +pub const KTR_MALLOC: u32 = 128; +pub const KTR_TRAP: u32 = 256; +pub const KTR_INTR: u32 = 512; +pub const KTR_SIG: u32 = 1024; +pub const KTR_SPARE2: u32 = 2048; +pub const KTR_PROC: u32 = 4096; +pub const KTR_SYSC: u32 = 8192; +pub const KTR_INIT: u32 = 16384; +pub const KTR_SPARE3: u32 = 32768; +pub const KTR_SPARE4: u32 = 65536; +pub const KTR_EVH: u32 = 131072; +pub const KTR_VFS: u32 = 262144; +pub const KTR_VOP: u32 = 524288; +pub const KTR_VM: u32 = 1048576; +pub const KTR_INET: u32 = 2097152; +pub const KTR_RUNQ: u32 = 4194304; +pub const KTR_SPARE5: u32 = 8388608; +pub const KTR_UMA: u32 = 16777216; +pub const KTR_CALLOUT: u32 = 33554432; +pub const KTR_GEOM: u32 = 67108864; +pub const KTR_BUSDMA: u32 = 134217728; +pub const KTR_INET6: u32 = 268435456; +pub const KTR_SCHED: u32 = 536870912; +pub const KTR_BUF: u32 = 1073741824; +pub const KTR_PTRACE: u32 = 2147483648; +pub const KTR_ALL: u32 = 4294967295; +pub const KTR_COMPILE: u32 = 0; +pub const LC_SLEEPLOCK: u32 = 1; +pub const LC_SPINLOCK: u32 = 2; +pub const LC_SLEEPABLE: u32 = 4; +pub const LC_RECURSABLE: u32 = 8; +pub const LC_UPGRADABLE: u32 = 16; +pub const LO_CLASSFLAGS: u32 = 65535; +pub const LO_INITIALIZED: u32 = 65536; +pub const LO_WITNESS: u32 = 131072; +pub const LO_QUIET: u32 = 262144; +pub const LO_RECURSABLE: u32 = 524288; +pub const LO_SLEEPABLE: u32 = 1048576; +pub const LO_UPGRADABLE: u32 = 2097152; +pub const LO_DUPOK: u32 = 4194304; +pub const LO_IS_VNODE: u32 = 8388608; +pub const LO_CLASSMASK: u32 = 251658240; +pub const LO_NOPROFILE: u32 = 268435456; +pub const LO_NEW: u32 = 536870912; +pub const LO_CLASSSHIFT: u32 = 24; +pub const LOCK_CLASS_MAX: u32 = 15; +pub const LOP_NEWORDER: u32 = 1; +pub const LOP_QUIET: u32 = 2; +pub const LOP_TRYLOCK: u32 = 4; +pub const LOP_EXCLUSIVE: u32 = 8; +pub const LOP_DUPOK: u32 = 16; +pub const LOP_NOSLEEP: u32 = 32; +pub const LA_MASKASSERT: u32 = 255; +pub const LA_UNLOCKED: u32 = 0; +pub const LA_LOCKED: u32 = 1; +pub const LA_SLOCKED: u32 = 2; +pub const LA_XLOCKED: u32 = 4; +pub const LA_RECURSED: u32 = 8; +pub const LA_NOTRECURSED: u32 = 16; +pub const SX_LOCK_SHARED: u32 = 1; +pub const SX_LOCK_SHARED_WAITERS: u32 = 2; +pub const SX_LOCK_EXCLUSIVE_WAITERS: u32 = 4; +pub const SX_LOCK_WRITE_SPINNER: u32 = 8; +pub const SX_LOCK_RECURSED: u32 = 16; +pub const SX_LOCK_FLAGMASK: u32 = 31; +pub const SX_LOCK_WAITERS: u32 = 6; +pub const SX_SHARERS_SHIFT: u32 = 5; +pub const SX_ONE_SHARER: u32 = 32; +pub const SX_LOCK_DESTROYED: u32 = 6; +pub const SPLAY_NEGINF: i32 = -1; +pub const SPLAY_INF: u32 = 1; +pub const RB_STRICT_HST: u32 = 0; +pub const RB_NEGINF: i32 = -1; +pub const RB_INF: u32 = 1; +pub const UMA_SMALLEST_UNIT: u32 = 8; +pub const UMA_ZONE_UNMANAGED: u32 = 1; +pub const UMA_ZONE_ZINIT: u32 = 2; +pub const UMA_ZONE_CONTIG: u32 = 4; +pub const UMA_ZONE_NOTOUCH: u32 = 8; +pub const UMA_ZONE_MALLOC: u32 = 16; +pub const UMA_ZONE_NOFREE: u32 = 32; +pub const UMA_ZONE_MTXCLASS: u32 = 64; +pub const UMA_ZONE_VM: u32 = 128; +pub const UMA_ZONE_NOTPAGE: u32 = 256; +pub const UMA_ZONE_SECONDARY: u32 = 512; +pub const UMA_ZONE_NOBUCKET: u32 = 1024; +pub const UMA_ZONE_MAXBUCKET: u32 = 2048; +pub const UMA_ZONE_CACHESPREAD: u32 = 8192; +pub const UMA_ZONE_NODUMP: u32 = 16384; +pub const UMA_ZONE_PCPU: u32 = 32768; +pub const UMA_ZONE_FIRSTTOUCH: u32 = 65536; +pub const UMA_ZONE_ROUNDROBIN: u32 = 131072; +pub const UMA_ZONE_SMR: u32 = 262144; +pub const UMA_ZONE_NOKASAN: u32 = 524288; +pub const UMA_ZONE_INHERIT: u32 = 754104; +pub const UMA_ALIGN_CACHE: i32 = -1; +pub const UMA_ANYDOMAIN: i32 = -1; +pub const UMA_RECLAIM_DRAIN: u32 = 1; +pub const UMA_RECLAIM_DRAIN_CPU: u32 = 2; +pub const UMA_RECLAIM_TRIM: u32 = 3; +pub const UMA_SLAB_BOOT: u32 = 1; +pub const UMA_SLAB_KERNEL: u32 = 4; +pub const UMA_SLAB_PRIV: u32 = 8; +pub const UMA_STREAM_VERSION: u32 = 1; +pub const UTH_MAX_NAME: u32 = 32; +pub const UTH_ZONE_SECONDARY: u32 = 1; +pub const CLOCK_REALTIME: u32 = 0; +pub const CLOCK_VIRTUAL: u32 = 1; +pub const CLOCK_PROF: u32 = 2; +pub const CLOCK_MONOTONIC: u32 = 4; +pub const CLOCK_UPTIME_FAST: u32 = 8; +pub const CLOCK_UPTIME: u32 = 5; +pub const CLOCK_UPTIME_PRECISE: u32 = 7; +pub const CLOCK_REALTIME_PRECISE: u32 = 9; +pub const CLOCK_REALTIME_FAST: u32 = 10; +pub const CLOCK_MONOTONIC_PRECISE: u32 = 11; +pub const CLOCK_MONOTONIC_FAST: u32 = 12; +pub const CLOCK_SECOND: u32 = 13; +pub const CLOCK_THREAD_CPUTIME_ID: u32 = 14; +pub const CLOCK_PROCESS_CPUTIME_ID: u32 = 15; +pub const CLOCK_BOOTTIME: u32 = 5; +pub const CLOCK_REALTIME_COARSE: u32 = 10; +pub const CLOCK_MONOTONIC_COARSE: u32 = 12; +pub const TIMER_RELTIME: u32 = 0; +pub const TIMER_ABSTIME: u32 = 1; +pub const DST_NONE: u32 = 0; +pub const DST_USA: u32 = 1; +pub const DST_AUST: u32 = 2; +pub const DST_WET: u32 = 3; +pub const DST_MET: u32 = 4; +pub const DST_EET: u32 = 5; +pub const DST_CAN: u32 = 6; +pub const SBT_MAX: u64 = 9223372036854775807; +pub const ITIMER_REAL: u32 = 0; +pub const ITIMER_VIRTUAL: u32 = 1; +pub const ITIMER_PROF: u32 = 2; +pub const CPUCLOCK_WHICH_PID: u32 = 0; +pub const CPUCLOCK_WHICH_TID: u32 = 1; +pub const CLK_TCK: u32 = 128; +pub const CLOCKS_PER_SEC: u32 = 128; +pub const TIME_UTC: u32 = 1; +pub const TIME_MONOTONIC: u32 = 2; +pub const SOCK_STREAM: u32 = 1; +pub const SOCK_DGRAM: u32 = 2; +pub const SOCK_RAW: u32 = 3; +pub const SOCK_RDM: u32 = 4; +pub const SOCK_SEQPACKET: u32 = 5; +pub const SOCK_CLOEXEC: u32 = 268435456; +pub const SOCK_NONBLOCK: u32 = 536870912; +pub const SO_DEBUG: u32 = 1; +pub const SO_ACCEPTCONN: u32 = 2; +pub const SO_REUSEADDR: u32 = 4; +pub const SO_KEEPALIVE: u32 = 8; +pub const SO_DONTROUTE: u32 = 16; +pub const SO_BROADCAST: u32 = 32; +pub const SO_USELOOPBACK: u32 = 64; +pub const SO_LINGER: u32 = 128; +pub const SO_OOBINLINE: u32 = 256; +pub const SO_REUSEPORT: u32 = 512; +pub const SO_TIMESTAMP: u32 = 1024; +pub const SO_NOSIGPIPE: u32 = 2048; +pub const SO_ACCEPTFILTER: u32 = 4096; +pub const SO_BINTIME: u32 = 8192; +pub const SO_NO_OFFLOAD: u32 = 16384; +pub const SO_NO_DDP: u32 = 32768; +pub const SO_REUSEPORT_LB: u32 = 65536; +pub const SO_RERROR: u32 = 131072; +pub const SO_SNDBUF: u32 = 4097; +pub const SO_RCVBUF: u32 = 4098; +pub const SO_SNDLOWAT: u32 = 4099; +pub const SO_RCVLOWAT: u32 = 4100; +pub const SO_SNDTIMEO: u32 = 4101; +pub const SO_RCVTIMEO: u32 = 4102; +pub const SO_ERROR: u32 = 4103; +pub const SO_TYPE: u32 = 4104; +pub const SO_LABEL: u32 = 4105; +pub const SO_PEERLABEL: u32 = 4112; +pub const SO_LISTENQLIMIT: u32 = 4113; +pub const SO_LISTENQLEN: u32 = 4114; +pub const SO_LISTENINCQLEN: u32 = 4115; +pub const SO_SETFIB: u32 = 4116; +pub const SO_USER_COOKIE: u32 = 4117; +pub const SO_PROTOCOL: u32 = 4118; +pub const SO_PROTOTYPE: u32 = 4118; +pub const SO_TS_CLOCK: u32 = 4119; +pub const SO_MAX_PACING_RATE: u32 = 4120; +pub const SO_DOMAIN: u32 = 4121; +pub const SO_TS_REALTIME_MICRO: u32 = 0; +pub const SO_TS_BINTIME: u32 = 1; +pub const SO_TS_REALTIME: u32 = 2; +pub const SO_TS_MONOTONIC: u32 = 3; +pub const SO_TS_DEFAULT: u32 = 0; +pub const SO_TS_CLOCK_MAX: u32 = 3; +pub const SO_VENDOR: u32 = 2147483648; +pub const SOL_SOCKET: u32 = 65535; +pub const AF_UNSPEC: u32 = 0; +pub const AF_UNIX: u32 = 1; +pub const AF_INET: u32 = 2; +pub const AF_IMPLINK: u32 = 3; +pub const AF_PUP: u32 = 4; +pub const AF_CHAOS: u32 = 5; +pub const AF_NETBIOS: u32 = 6; +pub const AF_ISO: u32 = 7; +pub const AF_OSI: u32 = 7; +pub const AF_ECMA: u32 = 8; +pub const AF_DATAKIT: u32 = 9; +pub const AF_CCITT: u32 = 10; +pub const AF_SNA: u32 = 11; +pub const AF_DECnet: u32 = 12; +pub const AF_DLI: u32 = 13; +pub const AF_LAT: u32 = 14; +pub const AF_HYLINK: u32 = 15; +pub const AF_APPLETALK: u32 = 16; +pub const AF_ROUTE: u32 = 17; +pub const AF_LINK: u32 = 18; +pub const pseudo_AF_XTP: u32 = 19; +pub const AF_COIP: u32 = 20; +pub const AF_CNT: u32 = 21; +pub const pseudo_AF_RTIP: u32 = 22; +pub const AF_IPX: u32 = 23; +pub const AF_SIP: u32 = 24; +pub const pseudo_AF_PIP: u32 = 25; +pub const AF_ISDN: u32 = 26; +pub const AF_E164: u32 = 26; +pub const pseudo_AF_KEY: u32 = 27; +pub const AF_INET6: u32 = 28; +pub const AF_NATM: u32 = 29; +pub const AF_ATM: u32 = 30; +pub const pseudo_AF_HDRCMPLT: u32 = 31; +pub const AF_NETGRAPH: u32 = 32; +pub const AF_SLOW: u32 = 33; +pub const AF_SCLUSTER: u32 = 34; +pub const AF_ARP: u32 = 35; +pub const AF_BLUETOOTH: u32 = 36; +pub const AF_IEEE80211: u32 = 37; +pub const AF_NETLINK: u32 = 38; +pub const AF_INET_SDP: u32 = 40; +pub const AF_INET6_SDP: u32 = 42; +pub const AF_HYPERV: u32 = 43; +pub const AF_DIVERT: u32 = 44; +pub const AF_MAX: u32 = 44; +pub const AF_VENDOR00: u32 = 39; +pub const AF_VENDOR01: u32 = 41; +pub const AF_VENDOR03: u32 = 45; +pub const AF_VENDOR04: u32 = 47; +pub const AF_VENDOR05: u32 = 49; +pub const AF_VENDOR06: u32 = 51; +pub const AF_VENDOR07: u32 = 53; +pub const AF_VENDOR08: u32 = 55; +pub const AF_VENDOR09: u32 = 57; +pub const AF_VENDOR10: u32 = 59; +pub const AF_VENDOR11: u32 = 61; +pub const AF_VENDOR12: u32 = 63; +pub const AF_VENDOR13: u32 = 65; +pub const AF_VENDOR14: u32 = 67; +pub const AF_VENDOR15: u32 = 69; +pub const AF_VENDOR16: u32 = 71; +pub const AF_VENDOR17: u32 = 73; +pub const AF_VENDOR18: u32 = 75; +pub const AF_VENDOR19: u32 = 77; +pub const AF_VENDOR20: u32 = 79; +pub const AF_VENDOR21: u32 = 81; +pub const AF_VENDOR22: u32 = 83; +pub const AF_VENDOR23: u32 = 85; +pub const AF_VENDOR24: u32 = 87; +pub const AF_VENDOR25: u32 = 89; +pub const AF_VENDOR26: u32 = 91; +pub const AF_VENDOR27: u32 = 93; +pub const AF_VENDOR28: u32 = 95; +pub const AF_VENDOR29: u32 = 97; +pub const AF_VENDOR30: u32 = 99; +pub const AF_VENDOR31: u32 = 101; +pub const AF_VENDOR32: u32 = 103; +pub const AF_VENDOR33: u32 = 105; +pub const AF_VENDOR34: u32 = 107; +pub const AF_VENDOR35: u32 = 109; +pub const AF_VENDOR36: u32 = 111; +pub const AF_VENDOR37: u32 = 113; +pub const AF_VENDOR38: u32 = 115; +pub const AF_VENDOR39: u32 = 117; +pub const AF_VENDOR40: u32 = 119; +pub const AF_VENDOR41: u32 = 121; +pub const AF_VENDOR42: u32 = 123; +pub const AF_VENDOR43: u32 = 125; +pub const AF_VENDOR44: u32 = 127; +pub const AF_VENDOR45: u32 = 129; +pub const AF_VENDOR46: u32 = 131; +pub const AF_VENDOR47: u32 = 133; +pub const SOCK_MAXADDRLEN: u32 = 255; +pub const _SS_MAXSIZE: u32 = 128; +pub const PF_UNSPEC: u32 = 0; +pub const PF_INET: u32 = 2; +pub const PF_IMPLINK: u32 = 3; +pub const PF_PUP: u32 = 4; +pub const PF_CHAOS: u32 = 5; +pub const PF_NETBIOS: u32 = 6; +pub const PF_ISO: u32 = 7; +pub const PF_OSI: u32 = 7; +pub const PF_ECMA: u32 = 8; +pub const PF_DATAKIT: u32 = 9; +pub const PF_CCITT: u32 = 10; +pub const PF_SNA: u32 = 11; +pub const PF_DECnet: u32 = 12; +pub const PF_DLI: u32 = 13; +pub const PF_LAT: u32 = 14; +pub const PF_HYLINK: u32 = 15; +pub const PF_APPLETALK: u32 = 16; +pub const PF_ROUTE: u32 = 17; +pub const PF_LINK: u32 = 18; +pub const PF_XTP: u32 = 19; +pub const PF_COIP: u32 = 20; +pub const PF_CNT: u32 = 21; +pub const PF_SIP: u32 = 24; +pub const PF_IPX: u32 = 23; +pub const PF_RTIP: u32 = 22; +pub const PF_PIP: u32 = 25; +pub const PF_ISDN: u32 = 26; +pub const PF_KEY: u32 = 27; +pub const PF_INET6: u32 = 28; +pub const PF_NATM: u32 = 29; +pub const PF_ATM: u32 = 30; +pub const PF_NETGRAPH: u32 = 32; +pub const PF_SLOW: u32 = 33; +pub const PF_SCLUSTER: u32 = 34; +pub const PF_ARP: u32 = 35; +pub const PF_BLUETOOTH: u32 = 36; +pub const PF_IEEE80211: u32 = 37; +pub const PF_NETLINK: u32 = 38; +pub const PF_INET_SDP: u32 = 40; +pub const PF_INET6_SDP: u32 = 42; +pub const PF_DIVERT: u32 = 44; +pub const PF_MAX: u32 = 44; +pub const NET_RT_DUMP: u32 = 1; +pub const NET_RT_FLAGS: u32 = 2; +pub const NET_RT_IFLIST: u32 = 3; +pub const NET_RT_IFMALIST: u32 = 4; +pub const NET_RT_IFLISTL: u32 = 5; +pub const NET_RT_NHOP: u32 = 6; +pub const NET_RT_NHGRP: u32 = 7; +pub const SOMAXCONN: u32 = 128; +pub const MSG_OOB: u32 = 1; +pub const MSG_PEEK: u32 = 2; +pub const MSG_DONTROUTE: u32 = 4; +pub const MSG_EOR: u32 = 8; +pub const MSG_TRUNC: u32 = 16; +pub const MSG_CTRUNC: u32 = 32; +pub const MSG_WAITALL: u32 = 64; +pub const MSG_DONTWAIT: u32 = 128; +pub const MSG_EOF: u32 = 256; +pub const MSG_NOTIFICATION: u32 = 8192; +pub const MSG_NBIO: u32 = 16384; +pub const MSG_COMPAT: u32 = 32768; +pub const MSG_NOSIGNAL: u32 = 131072; +pub const MSG_CMSG_CLOEXEC: u32 = 262144; +pub const MSG_WAITFORONE: u32 = 524288; +pub const CMGROUP_MAX: u32 = 16; +pub const SCM_RIGHTS: u32 = 1; +pub const SCM_TIMESTAMP: u32 = 2; +pub const SCM_CREDS: u32 = 3; +pub const SCM_BINTIME: u32 = 4; +pub const SCM_REALTIME: u32 = 5; +pub const SCM_MONOTONIC: u32 = 6; +pub const SCM_TIME_INFO: u32 = 7; +pub const SCM_CREDS2: u32 = 8; +pub const ST_INFO_HW: u32 = 1; +pub const ST_INFO_HW_HPREC: u32 = 2; +pub const SHUT_RD: u32 = 0; +pub const SHUT_WR: u32 = 1; +pub const SHUT_RDWR: u32 = 2; +pub const PRU_FLUSH_RD: u32 = 0; +pub const PRU_FLUSH_WR: u32 = 1; +pub const PRU_FLUSH_RDWR: u32 = 2; +pub const SF_NODISKIO: u32 = 1; +pub const SF_MNOWAIT: u32 = 2; +pub const SF_SYNC: u32 = 4; +pub const SF_USER_READAHEAD: u32 = 8; +pub const SF_NOCACHE: u32 = 16; +pub const IF_NAMESIZE: u32 = 16; +pub const IFNAMSIZ: u32 = 16; +pub const IF_MAXUNIT: u32 = 32767; +pub const IFF_UP: u32 = 1; +pub const IFF_BROADCAST: u32 = 2; +pub const IFF_DEBUG: u32 = 4; +pub const IFF_LOOPBACK: u32 = 8; +pub const IFF_POINTOPOINT: u32 = 16; +pub const IFF_NEEDSEPOCH: u32 = 32; +pub const IFF_DRV_RUNNING: u32 = 64; +pub const IFF_NOARP: u32 = 128; +pub const IFF_PROMISC: u32 = 256; +pub const IFF_ALLMULTI: u32 = 512; +pub const IFF_DRV_OACTIVE: u32 = 1024; +pub const IFF_SIMPLEX: u32 = 2048; +pub const IFF_LINK0: u32 = 4096; +pub const IFF_LINK1: u32 = 8192; +pub const IFF_LINK2: u32 = 16384; +pub const IFF_ALTPHYS: u32 = 16384; +pub const IFF_MULTICAST: u32 = 32768; +pub const IFF_CANTCONFIG: u32 = 65536; +pub const IFF_PPROMISC: u32 = 131072; +pub const IFF_MONITOR: u32 = 262144; +pub const IFF_STATICARP: u32 = 524288; +pub const IFF_STICKYARP: u32 = 1048576; +pub const IFF_DYING: u32 = 2097152; +pub const IFF_RENAMING: u32 = 4194304; +pub const IFF_SPARE: u32 = 8388608; +pub const IFF_NETLINK_1: u32 = 16777216; +pub const IFF_RUNNING: u32 = 64; +pub const IFF_OACTIVE: u32 = 1024; +pub const IFF_CANTCHANGE: u32 = 2199410; +pub const LINK_STATE_UNKNOWN: u32 = 0; +pub const LINK_STATE_DOWN: u32 = 1; +pub const LINK_STATE_UP: u32 = 2; +pub const IFCAP_B_RXCSUM: u32 = 0; +pub const IFCAP_B_TXCSUM: u32 = 1; +pub const IFCAP_B_NETCONS: u32 = 2; +pub const IFCAP_B_VLAN_MTU: u32 = 3; +pub const IFCAP_B_VLAN_HWTAGGING: u32 = 4; +pub const IFCAP_B_JUMBO_MTU: u32 = 5; +pub const IFCAP_B_POLLING: u32 = 6; +pub const IFCAP_B_VLAN_HWCSUM: u32 = 7; +pub const IFCAP_B_TSO4: u32 = 8; +pub const IFCAP_B_TSO6: u32 = 9; +pub const IFCAP_B_LRO: u32 = 10; +pub const IFCAP_B_WOL_UCAST: u32 = 11; +pub const IFCAP_B_WOL_MCAST: u32 = 12; +pub const IFCAP_B_WOL_MAGIC: u32 = 13; +pub const IFCAP_B_TOE4: u32 = 14; +pub const IFCAP_B_TOE6: u32 = 15; +pub const IFCAP_B_VLAN_HWFILTER: u32 = 16; +pub const IFCAP_B_NV: u32 = 17; +pub const IFCAP_B_VLAN_HWTSO: u32 = 18; +pub const IFCAP_B_LINKSTATE: u32 = 19; +pub const IFCAP_B_NETMAP: u32 = 20; +pub const IFCAP_B_RXCSUM_IPV6: u32 = 21; +pub const IFCAP_B_TXCSUM_IPV6: u32 = 22; +pub const IFCAP_B_HWSTATS: u32 = 23; +pub const IFCAP_B_TXRTLMT: u32 = 24; +pub const IFCAP_B_HWRXTSTMP: u32 = 25; +pub const IFCAP_B_MEXTPG: u32 = 26; +pub const IFCAP_B_TXTLS4: u32 = 27; +pub const IFCAP_B_TXTLS6: u32 = 28; +pub const IFCAP_B_VXLAN_HWCSUM: u32 = 29; +pub const IFCAP_B_VXLAN_HWTSO: u32 = 30; +pub const IFCAP_B_TXTLS_RTLMT: u32 = 31; +pub const IFCAP_B_RXTLS4: u32 = 32; +pub const IFCAP_B_RXTLS6: u32 = 33; +pub const __IFCAP_B_SIZE: u32 = 34; +pub const IFCAP_B_SIZE: u32 = 34; +pub const IFCAP2_RXTLS4: u32 = 0; +pub const IFCAP2_RXTLS6: u32 = 1; +pub const IFCAP_ALLCAPS: u32 = 4294967295; +pub const IFQ_MAXLEN: u32 = 50; +pub const IFNET_SLOWHZ: u32 = 1; +pub const IFAN_ARRIVAL: u32 = 0; +pub const IFAN_DEPARTURE: u32 = 1; +pub const IFR_CAP_NV_MAXBUFSIZE: u32 = 2097152; +pub const IFSTATMAX: u32 = 800; +pub const IFG_ALL: &[u8; 4] = b"all\0"; +pub const IFG_EGRESS: &[u8; 7] = b"egress\0"; +pub const RSS_FUNC_NONE: u32 = 0; +pub const RSS_FUNC_PRIVATE: u32 = 1; +pub const RSS_FUNC_TOEPLITZ: u32 = 2; +pub const RSS_TYPE_IPV4: u32 = 1; +pub const RSS_TYPE_TCP_IPV4: u32 = 2; +pub const RSS_TYPE_IPV6: u32 = 4; +pub const RSS_TYPE_IPV6_EX: u32 = 8; +pub const RSS_TYPE_TCP_IPV6: u32 = 16; +pub const RSS_TYPE_TCP_IPV6_EX: u32 = 32; +pub const RSS_TYPE_UDP_IPV4: u32 = 64; +pub const RSS_TYPE_UDP_IPV6: u32 = 128; +pub const RSS_TYPE_UDP_IPV6_EX: u32 = 256; +pub const RSS_KEYLEN: u32 = 128; +pub const IFNET_PCP_NONE: u32 = 255; +pub const IFDR_MSG_SIZE: u32 = 64; +pub const IFDR_REASON_MSG: u32 = 1; +pub const IFDR_REASON_VENDOR: u32 = 2; +pub const ETHER_ADDR_LEN: u32 = 6; +pub const ETHER_TYPE_LEN: u32 = 2; +pub const ETHER_CRC_LEN: u32 = 4; +pub const ETHER_HDR_LEN: u32 = 14; +pub const ETHER_MIN_LEN: u32 = 64; +pub const ETHER_MAX_LEN: u32 = 1518; +pub const ETHER_MAX_LEN_JUMBO: u32 = 9018; +pub const ETHER_VLAN_ENCAP_LEN: u32 = 4; +pub const ETHER_ALIGN: u32 = 2; +pub const ETHER_CRC_POLY_LE: u32 = 3988292384; +pub const ETHER_CRC_POLY_BE: u32 = 79764918; +pub const EVL_VLID_MASK: u32 = 4095; +pub const EVL_PRI_MASK: u32 = 57344; +pub const ETHERTYPE_8023: u32 = 4; +pub const ETHERTYPE_PUP: u32 = 512; +pub const ETHERTYPE_PUPAT: u32 = 512; +pub const ETHERTYPE_SPRITE: u32 = 1280; +pub const ETHERTYPE_NS: u32 = 1536; +pub const ETHERTYPE_NSAT: u32 = 1537; +pub const ETHERTYPE_DLOG1: u32 = 1632; +pub const ETHERTYPE_DLOG2: u32 = 1633; +pub const ETHERTYPE_IP: u32 = 2048; +pub const ETHERTYPE_X75: u32 = 2049; +pub const ETHERTYPE_NBS: u32 = 2050; +pub const ETHERTYPE_ECMA: u32 = 2051; +pub const ETHERTYPE_CHAOS: u32 = 2052; +pub const ETHERTYPE_X25: u32 = 2053; +pub const ETHERTYPE_ARP: u32 = 2054; +pub const ETHERTYPE_NSCOMPAT: u32 = 2055; +pub const ETHERTYPE_FRARP: u32 = 2056; +pub const ETHERTYPE_UBDEBUG: u32 = 2304; +pub const ETHERTYPE_IEEEPUP: u32 = 2560; +pub const ETHERTYPE_IEEEPUPAT: u32 = 2561; +pub const ETHERTYPE_VINES: u32 = 2989; +pub const ETHERTYPE_VINESLOOP: u32 = 2990; +pub const ETHERTYPE_VINESECHO: u32 = 2991; +pub const ETHERTYPE_TRAIL: u32 = 4096; +pub const ETHERTYPE_NTRAILER: u32 = 16; +pub const ETHERTYPE_DCA: u32 = 4660; +pub const ETHERTYPE_VALID: u32 = 5632; +pub const ETHERTYPE_DOGFIGHT: u32 = 6537; +pub const ETHERTYPE_RCL: u32 = 6549; +pub const ETHERTYPE_NBPVCD: u32 = 15360; +pub const ETHERTYPE_NBPSCD: u32 = 15361; +pub const ETHERTYPE_NBPCREQ: u32 = 15362; +pub const ETHERTYPE_NBPCRSP: u32 = 15363; +pub const ETHERTYPE_NBPCC: u32 = 15364; +pub const ETHERTYPE_NBPCLREQ: u32 = 15365; +pub const ETHERTYPE_NBPCLRSP: u32 = 15366; +pub const ETHERTYPE_NBPDG: u32 = 15367; +pub const ETHERTYPE_NBPDGB: u32 = 15368; +pub const ETHERTYPE_NBPCLAIM: u32 = 15369; +pub const ETHERTYPE_NBPDLTE: u32 = 15370; +pub const ETHERTYPE_NBPRAS: u32 = 15371; +pub const ETHERTYPE_NBPRAR: u32 = 15372; +pub const ETHERTYPE_NBPRST: u32 = 15373; +pub const ETHERTYPE_PCS: u32 = 16962; +pub const ETHERTYPE_IMLBLDIAG: u32 = 16972; +pub const ETHERTYPE_DIDDLE: u32 = 17185; +pub const ETHERTYPE_IMLBL: u32 = 19522; +pub const ETHERTYPE_SIMNET: u32 = 21000; +pub const ETHERTYPE_DECEXPER: u32 = 24576; +pub const ETHERTYPE_MOPDL: u32 = 24577; +pub const ETHERTYPE_MOPRC: u32 = 24578; +pub const ETHERTYPE_DECnet: u32 = 24579; +pub const ETHERTYPE_DN: u32 = 24579; +pub const ETHERTYPE_LAT: u32 = 24580; +pub const ETHERTYPE_DECDIAG: u32 = 24581; +pub const ETHERTYPE_DECCUST: u32 = 24582; +pub const ETHERTYPE_SCA: u32 = 24583; +pub const ETHERTYPE_AMBER: u32 = 24584; +pub const ETHERTYPE_DECMUMPS: u32 = 24585; +pub const ETHERTYPE_TRANSETHER: u32 = 25944; +pub const ETHERTYPE_RAWFR: u32 = 25945; +pub const ETHERTYPE_UBDL: u32 = 28672; +pub const ETHERTYPE_UBNIU: u32 = 28673; +pub const ETHERTYPE_UBDIAGLOOP: u32 = 28674; +pub const ETHERTYPE_UBNMC: u32 = 28675; +pub const ETHERTYPE_UBBST: u32 = 28677; +pub const ETHERTYPE_OS9: u32 = 28679; +pub const ETHERTYPE_OS9NET: u32 = 28681; +pub const ETHERTYPE_RACAL: u32 = 28720; +pub const ETHERTYPE_PRIMENTS: u32 = 28721; +pub const ETHERTYPE_CABLETRON: u32 = 28724; +pub const ETHERTYPE_CRONUSVLN: u32 = 32771; +pub const ETHERTYPE_CRONUS: u32 = 32772; +pub const ETHERTYPE_HP: u32 = 32773; +pub const ETHERTYPE_NESTAR: u32 = 32774; +pub const ETHERTYPE_ATTSTANFORD: u32 = 32776; +pub const ETHERTYPE_EXCELAN: u32 = 32784; +pub const ETHERTYPE_SG_DIAG: u32 = 32787; +pub const ETHERTYPE_SG_NETGAMES: u32 = 32788; +pub const ETHERTYPE_SG_RESV: u32 = 32789; +pub const ETHERTYPE_SG_BOUNCE: u32 = 32790; +pub const ETHERTYPE_APOLLODOMAIN: u32 = 32793; +pub const ETHERTYPE_TYMSHARE: u32 = 32814; +pub const ETHERTYPE_TIGAN: u32 = 32815; +pub const ETHERTYPE_REVARP: u32 = 32821; +pub const ETHERTYPE_AEONIC: u32 = 32822; +pub const ETHERTYPE_IPXNEW: u32 = 32823; +pub const ETHERTYPE_LANBRIDGE: u32 = 32824; +pub const ETHERTYPE_DSMD: u32 = 32825; +pub const ETHERTYPE_ARGONAUT: u32 = 32826; +pub const ETHERTYPE_VAXELN: u32 = 32827; +pub const ETHERTYPE_DECDNS: u32 = 32828; +pub const ETHERTYPE_ENCRYPT: u32 = 32829; +pub const ETHERTYPE_DECDTS: u32 = 32830; +pub const ETHERTYPE_DECLTM: u32 = 32831; +pub const ETHERTYPE_DECNETBIOS: u32 = 32832; +pub const ETHERTYPE_DECLAST: u32 = 32833; +pub const ETHERTYPE_PLANNING: u32 = 32836; +pub const ETHERTYPE_DECAM: u32 = 32840; +pub const ETHERTYPE_EXPERDATA: u32 = 32841; +pub const ETHERTYPE_VEXP: u32 = 32859; +pub const ETHERTYPE_VPROD: u32 = 32860; +pub const ETHERTYPE_ES: u32 = 32861; +pub const ETHERTYPE_LITTLE: u32 = 32864; +pub const ETHERTYPE_COUNTERPOINT: u32 = 32866; +pub const ETHERTYPE_VEECO: u32 = 32871; +pub const ETHERTYPE_GENDYN: u32 = 32872; +pub const ETHERTYPE_ATT: u32 = 32873; +pub const ETHERTYPE_AUTOPHON: u32 = 32874; +pub const ETHERTYPE_COMDESIGN: u32 = 32876; +pub const ETHERTYPE_COMPUGRAPHIC: u32 = 32877; +pub const ETHERTYPE_MATRA: u32 = 32890; +pub const ETHERTYPE_DDE: u32 = 32891; +pub const ETHERTYPE_MERIT: u32 = 32892; +pub const ETHERTYPE_VLTLMAN: u32 = 32896; +pub const ETHERTYPE_ATALK: u32 = 32923; +pub const ETHERTYPE_AT: u32 = 32923; +pub const ETHERTYPE_APPLETALK: u32 = 32923; +pub const ETHERTYPE_SPIDER: u32 = 32927; +pub const ETHERTYPE_PACER: u32 = 32966; +pub const ETHERTYPE_APPLITEK: u32 = 32967; +pub const ETHERTYPE_SNA: u32 = 32981; +pub const ETHERTYPE_VARIAN: u32 = 32989; +pub const ETHERTYPE_RETIX: u32 = 33010; +pub const ETHERTYPE_AARP: u32 = 33011; +pub const ETHERTYPE_APOLLO: u32 = 33015; +pub const ETHERTYPE_VLAN: u32 = 33024; +pub const ETHERTYPE_BOFL: u32 = 33026; +pub const ETHERTYPE_WELLFLEET: u32 = 33027; +pub const ETHERTYPE_TALARIS: u32 = 33067; +pub const ETHERTYPE_WATERLOO: u32 = 33072; +pub const ETHERTYPE_HAYES: u32 = 33072; +pub const ETHERTYPE_VGLAB: u32 = 33073; +pub const ETHERTYPE_IPX: u32 = 33079; +pub const ETHERTYPE_NOVELL: u32 = 33080; +pub const ETHERTYPE_MUMPS: u32 = 33087; +pub const ETHERTYPE_AMOEBA: u32 = 33093; +pub const ETHERTYPE_FLIP: u32 = 33094; +pub const ETHERTYPE_VURESERVED: u32 = 33095; +pub const ETHERTYPE_LOGICRAFT: u32 = 33096; +pub const ETHERTYPE_NCD: u32 = 33097; +pub const ETHERTYPE_ALPHA: u32 = 33098; +pub const ETHERTYPE_SNMP: u32 = 33100; +pub const ETHERTYPE_TEC: u32 = 33103; +pub const ETHERTYPE_RATIONAL: u32 = 33104; +pub const ETHERTYPE_XTP: u32 = 33149; +pub const ETHERTYPE_SGITW: u32 = 33150; +pub const ETHERTYPE_HIPPI_FP: u32 = 33152; +pub const ETHERTYPE_STP: u32 = 33153; +pub const ETHERTYPE_MOTOROLA: u32 = 33165; +pub const ETHERTYPE_NETBEUI: u32 = 33169; +pub const ETHERTYPE_ACCTON: u32 = 33680; +pub const ETHERTYPE_TALARISMC: u32 = 34091; +pub const ETHERTYPE_KALPANA: u32 = 34178; +pub const ETHERTYPE_SECTRA: u32 = 34523; +pub const ETHERTYPE_IPV6: u32 = 34525; +pub const ETHERTYPE_DELTACON: u32 = 34526; +pub const ETHERTYPE_ATOMIC: u32 = 34527; +pub const ETHERTYPE_RDP: u32 = 34617; +pub const ETHERTYPE_MICP: u32 = 34618; +pub const ETHERTYPE_TCPCOMP: u32 = 34667; +pub const ETHERTYPE_IPAS: u32 = 34668; +pub const ETHERTYPE_SECUREDATA: u32 = 34669; +pub const ETHERTYPE_FLOWCONTROL: u32 = 34824; +pub const ETHERTYPE_SLOW: u32 = 34825; +pub const ETHERTYPE_PPP: u32 = 34827; +pub const ETHERTYPE_HITACHI: u32 = 34848; +pub const ETHERTYPE_TEST: u32 = 34850; +pub const ETHERTYPE_MPLS: u32 = 34887; +pub const ETHERTYPE_MPLS_MCAST: u32 = 34888; +pub const ETHERTYPE_AXIS: u32 = 34902; +pub const ETHERTYPE_PPPOEDISC: u32 = 34915; +pub const ETHERTYPE_PPPOE: u32 = 34916; +pub const ETHERTYPE_LANPROBE: u32 = 34952; +pub const ETHERTYPE_PAE: u32 = 34958; +pub const ETHERTYPE_PROFINET: u32 = 34962; +pub const ETHERTYPE_AOE: u32 = 34978; +pub const ETHERTYPE_ETHERCAT: u32 = 34980; +pub const ETHERTYPE_QINQ: u32 = 34984; +pub const ETHERTYPE_POWERLINK: u32 = 34987; +pub const ETHERTYPE_LLDP: u32 = 35020; +pub const ETHERTYPE_SERCOS: u32 = 35021; +pub const ETHERTYPE_MACSEC: u32 = 35045; +pub const ETHERTYPE_PBB: u32 = 35047; +pub const ETHERTYPE_FCOE: u32 = 35078; +pub const ETHERTYPE_LOOPBACK: u32 = 36864; +pub const ETHERTYPE_8021Q9100: u32 = 37120; +pub const ETHERTYPE_LBACK: u32 = 36864; +pub const ETHERTYPE_XNSSM: u32 = 36865; +pub const ETHERTYPE_TCPSM: u32 = 36866; +pub const ETHERTYPE_BCLOOP: u32 = 36867; +pub const ETHERTYPE_8021Q9200: u32 = 37376; +pub const ETHERTYPE_8021Q9300: u32 = 37632; +pub const ETHERTYPE_DEBNI: u32 = 43690; +pub const ETHERTYPE_SONIX: u32 = 64245; +pub const ETHERTYPE_VITAL: u32 = 65280; +pub const ETHERTYPE_MAX: u32 = 65535; +pub const ETHERMTU: u32 = 1500; +pub const ETHERMIN: u32 = 46; +pub const ETHERMTU_JUMBO: u32 = 9000; +pub const IEEE8021Q_PCP_BK: u32 = 1; +pub const IEEE8021Q_PCP_BE: u32 = 0; +pub const IEEE8021Q_PCP_EE: u32 = 2; +pub const IEEE8021Q_PCP_CA: u32 = 3; +pub const IEEE8021Q_PCP_VI: u32 = 4; +pub const IEEE8021Q_PCP_VO: u32 = 5; +pub const IEEE8021Q_PCP_IC: u32 = 6; +pub const IEEE8021Q_PCP_NC: u32 = 7; +pub const RNF_NORMAL: u32 = 1; +pub const RNF_ROOT: u32 = 2; +pub const RNF_ACTIVE: u32 = 4; +pub const IPPROTO_IP: u32 = 0; +pub const IPPROTO_ICMP: u32 = 1; +pub const IPPROTO_TCP: u32 = 6; +pub const IPPROTO_UDP: u32 = 17; +pub const IPPROTO_IPV6: u32 = 41; +pub const IPPROTO_RAW: u32 = 255; +pub const INET_ADDRSTRLEN: u32 = 16; +pub const IPPROTO_HOPOPTS: u32 = 0; +pub const IPPROTO_IGMP: u32 = 2; +pub const IPPROTO_GGP: u32 = 3; +pub const IPPROTO_IPV4: u32 = 4; +pub const IPPROTO_IPIP: u32 = 4; +pub const IPPROTO_ST: u32 = 7; +pub const IPPROTO_EGP: u32 = 8; +pub const IPPROTO_PIGP: u32 = 9; +pub const IPPROTO_RCCMON: u32 = 10; +pub const IPPROTO_NVPII: u32 = 11; +pub const IPPROTO_PUP: u32 = 12; +pub const IPPROTO_ARGUS: u32 = 13; +pub const IPPROTO_EMCON: u32 = 14; +pub const IPPROTO_XNET: u32 = 15; +pub const IPPROTO_CHAOS: u32 = 16; +pub const IPPROTO_MUX: u32 = 18; +pub const IPPROTO_MEAS: u32 = 19; +pub const IPPROTO_HMP: u32 = 20; +pub const IPPROTO_PRM: u32 = 21; +pub const IPPROTO_IDP: u32 = 22; +pub const IPPROTO_TRUNK1: u32 = 23; +pub const IPPROTO_TRUNK2: u32 = 24; +pub const IPPROTO_LEAF1: u32 = 25; +pub const IPPROTO_LEAF2: u32 = 26; +pub const IPPROTO_RDP: u32 = 27; +pub const IPPROTO_IRTP: u32 = 28; +pub const IPPROTO_TP: u32 = 29; +pub const IPPROTO_BLT: u32 = 30; +pub const IPPROTO_NSP: u32 = 31; +pub const IPPROTO_INP: u32 = 32; +pub const IPPROTO_DCCP: u32 = 33; +pub const IPPROTO_3PC: u32 = 34; +pub const IPPROTO_IDPR: u32 = 35; +pub const IPPROTO_XTP: u32 = 36; +pub const IPPROTO_DDP: u32 = 37; +pub const IPPROTO_CMTP: u32 = 38; +pub const IPPROTO_TPXX: u32 = 39; +pub const IPPROTO_IL: u32 = 40; +pub const IPPROTO_SDRP: u32 = 42; +pub const IPPROTO_ROUTING: u32 = 43; +pub const IPPROTO_FRAGMENT: u32 = 44; +pub const IPPROTO_IDRP: u32 = 45; +pub const IPPROTO_RSVP: u32 = 46; +pub const IPPROTO_GRE: u32 = 47; +pub const IPPROTO_MHRP: u32 = 48; +pub const IPPROTO_BHA: u32 = 49; +pub const IPPROTO_ESP: u32 = 50; +pub const IPPROTO_AH: u32 = 51; +pub const IPPROTO_INLSP: u32 = 52; +pub const IPPROTO_SWIPE: u32 = 53; +pub const IPPROTO_NHRP: u32 = 54; +pub const IPPROTO_MOBILE: u32 = 55; +pub const IPPROTO_TLSP: u32 = 56; +pub const IPPROTO_SKIP: u32 = 57; +pub const IPPROTO_ICMPV6: u32 = 58; +pub const IPPROTO_NONE: u32 = 59; +pub const IPPROTO_DSTOPTS: u32 = 60; +pub const IPPROTO_AHIP: u32 = 61; +pub const IPPROTO_CFTP: u32 = 62; +pub const IPPROTO_HELLO: u32 = 63; +pub const IPPROTO_SATEXPAK: u32 = 64; +pub const IPPROTO_KRYPTOLAN: u32 = 65; +pub const IPPROTO_RVD: u32 = 66; +pub const IPPROTO_IPPC: u32 = 67; +pub const IPPROTO_ADFS: u32 = 68; +pub const IPPROTO_SATMON: u32 = 69; +pub const IPPROTO_VISA: u32 = 70; +pub const IPPROTO_IPCV: u32 = 71; +pub const IPPROTO_CPNX: u32 = 72; +pub const IPPROTO_CPHB: u32 = 73; +pub const IPPROTO_WSN: u32 = 74; +pub const IPPROTO_PVP: u32 = 75; +pub const IPPROTO_BRSATMON: u32 = 76; +pub const IPPROTO_ND: u32 = 77; +pub const IPPROTO_WBMON: u32 = 78; +pub const IPPROTO_WBEXPAK: u32 = 79; +pub const IPPROTO_EON: u32 = 80; +pub const IPPROTO_VMTP: u32 = 81; +pub const IPPROTO_SVMTP: u32 = 82; +pub const IPPROTO_VINES: u32 = 83; +pub const IPPROTO_TTP: u32 = 84; +pub const IPPROTO_IGP: u32 = 85; +pub const IPPROTO_DGP: u32 = 86; +pub const IPPROTO_TCF: u32 = 87; +pub const IPPROTO_IGRP: u32 = 88; +pub const IPPROTO_OSPFIGP: u32 = 89; +pub const IPPROTO_SRPC: u32 = 90; +pub const IPPROTO_LARP: u32 = 91; +pub const IPPROTO_MTP: u32 = 92; +pub const IPPROTO_AX25: u32 = 93; +pub const IPPROTO_IPEIP: u32 = 94; +pub const IPPROTO_MICP: u32 = 95; +pub const IPPROTO_SCCSP: u32 = 96; +pub const IPPROTO_ETHERIP: u32 = 97; +pub const IPPROTO_ENCAP: u32 = 98; +pub const IPPROTO_APES: u32 = 99; +pub const IPPROTO_GMTP: u32 = 100; +pub const IPPROTO_IPCOMP: u32 = 108; +pub const IPPROTO_SCTP: u32 = 132; +pub const IPPROTO_MH: u32 = 135; +pub const IPPROTO_UDPLITE: u32 = 136; +pub const IPPROTO_HIP: u32 = 139; +pub const IPPROTO_SHIM6: u32 = 140; +pub const IPPROTO_PIM: u32 = 103; +pub const IPPROTO_CARP: u32 = 112; +pub const IPPROTO_PGM: u32 = 113; +pub const IPPROTO_MPLS: u32 = 137; +pub const IPPROTO_PFSYNC: u32 = 240; +pub const IPPROTO_RESERVED_253: u32 = 253; +pub const IPPROTO_RESERVED_254: u32 = 254; +pub const IPPROTO_OLD_DIVERT: u32 = 254; +pub const IPPROTO_MAX: u32 = 256; +pub const IPPROTO_DONE: u32 = 257; +pub const IPPROTO_DIVERT: u32 = 258; +pub const IPPROTO_SEND: u32 = 259; +pub const IPPROTO_SPACER: u32 = 32767; +pub const IPPORT_RESERVED: u32 = 1024; +pub const IPPORT_EPHEMERALFIRST: u32 = 10000; +pub const IPPORT_EPHEMERALLAST: u32 = 65535; +pub const IPPORT_HIFIRSTAUTO: u32 = 49152; +pub const IPPORT_HILASTAUTO: u32 = 65535; +pub const IPPORT_RESERVEDSTART: u32 = 600; +pub const IPPORT_MAX: u32 = 65535; +pub const IN_CLASSA_NET: u32 = 4278190080; +pub const IN_CLASSA_NSHIFT: u32 = 24; +pub const IN_CLASSA_HOST: u32 = 16777215; +pub const IN_CLASSA_MAX: u32 = 128; +pub const IN_CLASSB_NET: u32 = 4294901760; +pub const IN_CLASSB_NSHIFT: u32 = 16; +pub const IN_CLASSB_HOST: u32 = 65535; +pub const IN_CLASSB_MAX: u32 = 65536; +pub const IN_CLASSC_NET: u32 = 4294967040; +pub const IN_CLASSC_NSHIFT: u32 = 8; +pub const IN_CLASSC_HOST: u32 = 255; +pub const IN_NETMASK_DEFAULT: u32 = 4294967040; +pub const IN_CLASSD_NET: u32 = 4026531840; +pub const IN_CLASSD_NSHIFT: u32 = 28; +pub const IN_CLASSD_HOST: u32 = 268435455; +pub const IN_LOOPBACKNET: u32 = 127; +pub const IP_OPTIONS: u32 = 1; +pub const IP_HDRINCL: u32 = 2; +pub const IP_TOS: u32 = 3; +pub const IP_TTL: u32 = 4; +pub const IP_RECVOPTS: u32 = 5; +pub const IP_RECVRETOPTS: u32 = 6; +pub const IP_RECVDSTADDR: u32 = 7; +pub const IP_SENDSRCADDR: u32 = 7; +pub const IP_RETOPTS: u32 = 8; +pub const IP_MULTICAST_IF: u32 = 9; +pub const IP_MULTICAST_TTL: u32 = 10; +pub const IP_MULTICAST_LOOP: u32 = 11; +pub const IP_ADD_MEMBERSHIP: u32 = 12; +pub const IP_DROP_MEMBERSHIP: u32 = 13; +pub const IP_MULTICAST_VIF: u32 = 14; +pub const IP_RSVP_ON: u32 = 15; +pub const IP_RSVP_OFF: u32 = 16; +pub const IP_RSVP_VIF_ON: u32 = 17; +pub const IP_RSVP_VIF_OFF: u32 = 18; +pub const IP_PORTRANGE: u32 = 19; +pub const IP_RECVIF: u32 = 20; +pub const IP_IPSEC_POLICY: u32 = 21; +pub const IP_ONESBCAST: u32 = 23; +pub const IP_BINDANY: u32 = 24; +pub const IP_ORIGDSTADDR: u32 = 27; +pub const IP_RECVORIGDSTADDR: u32 = 27; +pub const IP_FW_TABLE_ADD: u32 = 40; +pub const IP_FW_TABLE_DEL: u32 = 41; +pub const IP_FW_TABLE_FLUSH: u32 = 42; +pub const IP_FW_TABLE_GETSIZE: u32 = 43; +pub const IP_FW_TABLE_LIST: u32 = 44; +pub const IP_FW3: u32 = 48; +pub const IP_DUMMYNET3: u32 = 49; +pub const IP_FW_ADD: u32 = 50; +pub const IP_FW_DEL: u32 = 51; +pub const IP_FW_FLUSH: u32 = 52; +pub const IP_FW_ZERO: u32 = 53; +pub const IP_FW_GET: u32 = 54; +pub const IP_FW_RESETLOG: u32 = 55; +pub const IP_FW_NAT_CFG: u32 = 56; +pub const IP_FW_NAT_DEL: u32 = 57; +pub const IP_FW_NAT_GET_CONFIG: u32 = 58; +pub const IP_FW_NAT_GET_LOG: u32 = 59; +pub const IP_DUMMYNET_CONFIGURE: u32 = 60; +pub const IP_DUMMYNET_DEL: u32 = 61; +pub const IP_DUMMYNET_FLUSH: u32 = 62; +pub const IP_DUMMYNET_GET: u32 = 64; +pub const IP_RECVTTL: u32 = 65; +pub const IP_MINTTL: u32 = 66; +pub const IP_DONTFRAG: u32 = 67; +pub const IP_RECVTOS: u32 = 68; +pub const IP_ADD_SOURCE_MEMBERSHIP: u32 = 70; +pub const IP_DROP_SOURCE_MEMBERSHIP: u32 = 71; +pub const IP_BLOCK_SOURCE: u32 = 72; +pub const IP_UNBLOCK_SOURCE: u32 = 73; +pub const IP_MSFILTER: u32 = 74; +pub const IP_VLAN_PCP: u32 = 75; +pub const MCAST_JOIN_GROUP: u32 = 80; +pub const MCAST_LEAVE_GROUP: u32 = 81; +pub const MCAST_JOIN_SOURCE_GROUP: u32 = 82; +pub const MCAST_LEAVE_SOURCE_GROUP: u32 = 83; +pub const MCAST_BLOCK_SOURCE: u32 = 84; +pub const MCAST_UNBLOCK_SOURCE: u32 = 85; +pub const IP_FLOWID: u32 = 90; +pub const IP_FLOWTYPE: u32 = 91; +pub const IP_RSSBUCKETID: u32 = 92; +pub const IP_RECVFLOWID: u32 = 93; +pub const IP_RECVRSSBUCKETID: u32 = 94; +pub const IP_DEFAULT_MULTICAST_TTL: u32 = 1; +pub const IP_DEFAULT_MULTICAST_LOOP: u32 = 1; +pub const IP_MAX_MEMBERSHIPS: u32 = 4095; +pub const IP_MAX_GROUP_SRC_FILTER: u32 = 512; +pub const IP_MAX_SOCK_SRC_FILTER: u32 = 128; +pub const IP_MAX_SOCK_MUTE_FILTER: u32 = 128; +pub const MCAST_UNDEFINED: u32 = 0; +pub const MCAST_INCLUDE: u32 = 1; +pub const MCAST_EXCLUDE: u32 = 2; +pub const IP_PORTRANGE_DEFAULT: u32 = 0; +pub const IP_PORTRANGE_HIGH: u32 = 1; +pub const IP_PORTRANGE_LOW: u32 = 2; +pub const IPCTL_FORWARDING: u32 = 1; +pub const IPCTL_SENDREDIRECTS: u32 = 2; +pub const IPCTL_DEFTTL: u32 = 3; +pub const IPCTL_SOURCEROUTE: u32 = 8; +pub const IPCTL_DIRECTEDBROADCAST: u32 = 9; +pub const IPCTL_INTRQMAXLEN: u32 = 10; +pub const IPCTL_INTRQDROPS: u32 = 11; +pub const IPCTL_STATS: u32 = 12; +pub const IPCTL_ACCEPTSOURCEROUTE: u32 = 13; +pub const IPCTL_FASTFORWARDING: u32 = 14; +pub const IPCTL_GIF_TTL: u32 = 16; +pub const IPCTL_INTRDQMAXLEN: u32 = 17; +pub const IPCTL_INTRDQDROPS: u32 = 18; +pub const __KAME_VERSION: &[u8; 8] = b"FreeBSD\0"; +pub const IPV6PORT_RESERVED: u32 = 1024; +pub const IPV6PORT_ANONMIN: u32 = 49152; +pub const IPV6PORT_ANONMAX: u32 = 65535; +pub const IPV6PORT_RESERVEDMIN: u32 = 600; +pub const IPV6PORT_RESERVEDMAX: u32 = 1023; +pub const INET6_ADDRSTRLEN: u32 = 46; +pub const __IPV6_ADDR_SCOPE_NODELOCAL: u32 = 1; +pub const __IPV6_ADDR_SCOPE_INTFACELOCAL: u32 = 1; +pub const __IPV6_ADDR_SCOPE_LINKLOCAL: u32 = 2; +pub const __IPV6_ADDR_SCOPE_SITELOCAL: u32 = 5; +pub const __IPV6_ADDR_SCOPE_ORGLOCAL: u32 = 8; +pub const __IPV6_ADDR_SCOPE_GLOBAL: u32 = 14; +pub const IPV6_SOCKOPT_RESERVED1: u32 = 3; +pub const IPV6_UNICAST_HOPS: u32 = 4; +pub const IPV6_MULTICAST_IF: u32 = 9; +pub const IPV6_MULTICAST_HOPS: u32 = 10; +pub const IPV6_MULTICAST_LOOP: u32 = 11; +pub const IPV6_JOIN_GROUP: u32 = 12; +pub const IPV6_LEAVE_GROUP: u32 = 13; +pub const IPV6_PORTRANGE: u32 = 14; +pub const ICMP6_FILTER: u32 = 18; +pub const IPV6_CHECKSUM: u32 = 26; +pub const IPV6_V6ONLY: u32 = 27; +pub const IPV6_BINDV6ONLY: u32 = 27; +pub const IPV6_IPSEC_POLICY: u32 = 28; +pub const IPV6_FW_ADD: u32 = 30; +pub const IPV6_FW_DEL: u32 = 31; +pub const IPV6_FW_FLUSH: u32 = 32; +pub const IPV6_FW_ZERO: u32 = 33; +pub const IPV6_FW_GET: u32 = 34; +pub const IPV6_RTHDRDSTOPTS: u32 = 35; +pub const IPV6_RECVPKTINFO: u32 = 36; +pub const IPV6_RECVHOPLIMIT: u32 = 37; +pub const IPV6_RECVRTHDR: u32 = 38; +pub const IPV6_RECVHOPOPTS: u32 = 39; +pub const IPV6_RECVDSTOPTS: u32 = 40; +pub const IPV6_USE_MIN_MTU: u32 = 42; +pub const IPV6_RECVPATHMTU: u32 = 43; +pub const IPV6_PATHMTU: u32 = 44; +pub const IPV6_PKTINFO: u32 = 46; +pub const IPV6_HOPLIMIT: u32 = 47; +pub const IPV6_NEXTHOP: u32 = 48; +pub const IPV6_HOPOPTS: u32 = 49; +pub const IPV6_DSTOPTS: u32 = 50; +pub const IPV6_RTHDR: u32 = 51; +pub const IPV6_RECVTCLASS: u32 = 57; +pub const IPV6_AUTOFLOWLABEL: u32 = 59; +pub const IPV6_TCLASS: u32 = 61; +pub const IPV6_DONTFRAG: u32 = 62; +pub const IPV6_PREFER_TEMPADDR: u32 = 63; +pub const IPV6_BINDANY: u32 = 64; +pub const IPV6_FLOWID: u32 = 67; +pub const IPV6_FLOWTYPE: u32 = 68; +pub const IPV6_RSSBUCKETID: u32 = 69; +pub const IPV6_RECVFLOWID: u32 = 70; +pub const IPV6_RECVRSSBUCKETID: u32 = 71; +pub const IPV6_ORIGDSTADDR: u32 = 72; +pub const IPV6_RECVORIGDSTADDR: u32 = 72; +pub const IPV6_MSFILTER: u32 = 74; +pub const IPV6_VLAN_PCP: u32 = 75; +pub const IPV6_RTHDR_LOOSE: u32 = 0; +pub const IPV6_RTHDR_STRICT: u32 = 1; +pub const IPV6_RTHDR_TYPE_0: u32 = 0; +pub const IPV6_DEFAULT_MULTICAST_HOPS: u32 = 1; +pub const IPV6_DEFAULT_MULTICAST_LOOP: u32 = 1; +pub const IPV6_MAX_MEMBERSHIPS: u32 = 4095; +pub const IPV6_MAX_GROUP_SRC_FILTER: u32 = 512; +pub const IPV6_MAX_SOCK_SRC_FILTER: u32 = 128; +pub const IPV6_PORTRANGE_DEFAULT: u32 = 0; +pub const IPV6_PORTRANGE_HIGH: u32 = 1; +pub const IPV6_PORTRANGE_LOW: u32 = 2; +pub const IPV6PROTO_MAXID: u32 = 104; +pub const IPV6CTL_FORWARDING: u32 = 1; +pub const IPV6CTL_SENDREDIRECTS: u32 = 2; +pub const IPV6CTL_DEFHLIM: u32 = 3; +pub const IPV6CTL_FORWSRCRT: u32 = 5; +pub const IPV6CTL_STATS: u32 = 6; +pub const IPV6CTL_MRTSTATS: u32 = 7; +pub const IPV6CTL_MRTPROTO: u32 = 8; +pub const IPV6CTL_MAXFRAGPACKETS: u32 = 9; +pub const IPV6CTL_SOURCECHECK: u32 = 10; +pub const IPV6CTL_SOURCECHECK_LOGINT: u32 = 11; +pub const IPV6CTL_ACCEPT_RTADV: u32 = 12; +pub const IPV6CTL_LOG_INTERVAL: u32 = 14; +pub const IPV6CTL_HDRNESTLIMIT: u32 = 15; +pub const IPV6CTL_DAD_COUNT: u32 = 16; +pub const IPV6CTL_AUTO_FLOWLABEL: u32 = 17; +pub const IPV6CTL_DEFMCASTHLIM: u32 = 18; +pub const IPV6CTL_GIF_HLIM: u32 = 19; +pub const IPV6CTL_KAME_VERSION: u32 = 20; +pub const IPV6CTL_USE_DEPRECATED: u32 = 21; +pub const IPV6CTL_RR_PRUNE: u32 = 22; +pub const IPV6CTL_V6ONLY: u32 = 24; +pub const IPV6CTL_USETEMPADDR: u32 = 32; +pub const IPV6CTL_TEMPPLTIME: u32 = 33; +pub const IPV6CTL_TEMPVLTIME: u32 = 34; +pub const IPV6CTL_AUTO_LINKLOCAL: u32 = 35; +pub const IPV6CTL_RIP6STATS: u32 = 36; +pub const IPV6CTL_PREFER_TEMPADDR: u32 = 37; +pub const IPV6CTL_ADDRCTLPOLICY: u32 = 38; +pub const IPV6CTL_USE_DEFAULTZONE: u32 = 39; +pub const IPV6CTL_MAXFRAGS: u32 = 41; +pub const IPV6CTL_MCAST_PMTU: u32 = 44; +pub const IPV6CTL_STEALTH: u32 = 45; +pub const ICMPV6CTL_ND6_ONLINKNSRFC4861: u32 = 47; +pub const IPV6CTL_NO_RADR: u32 = 48; +pub const IPV6CTL_NORBIT_RAIF: u32 = 49; +pub const IPV6CTL_RFC6204W3: u32 = 50; +pub const IPV6CTL_INTRQMAXLEN: u32 = 51; +pub const IPV6CTL_INTRDQMAXLEN: u32 = 52; +pub const IPV6CTL_MAXFRAGSPERPACKET: u32 = 53; +pub const IPV6CTL_MAXFRAGBUCKETSIZE: u32 = 54; +pub const IPV6CTL_MAXID: u32 = 55; +pub const PF_MD5_DIGEST_LENGTH: u32 = 16; +pub const PFTM_TCP_FIRST_PACKET_VAL: u32 = 120; +pub const PFTM_TCP_OPENING_VAL: u32 = 30; +pub const PFTM_TCP_ESTABLISHED_VAL: u32 = 86400; +pub const PFTM_TCP_CLOSING_VAL: u32 = 900; +pub const PFTM_TCP_FIN_WAIT_VAL: u32 = 45; +pub const PFTM_TCP_CLOSED_VAL: u32 = 90; +pub const PFTM_UDP_FIRST_PACKET_VAL: u32 = 60; +pub const PFTM_UDP_SINGLE_VAL: u32 = 30; +pub const PFTM_UDP_MULTIPLE_VAL: u32 = 60; +pub const PFTM_ICMP_FIRST_PACKET_VAL: u32 = 20; +pub const PFTM_ICMP_ERROR_REPLY_VAL: u32 = 10; +pub const PFTM_OTHER_FIRST_PACKET_VAL: u32 = 60; +pub const PFTM_OTHER_SINGLE_VAL: u32 = 30; +pub const PFTM_OTHER_MULTIPLE_VAL: u32 = 60; +pub const PFTM_FRAG_VAL: u32 = 30; +pub const PFTM_INTERVAL_VAL: u32 = 10; +pub const PFTM_SRC_NODE_VAL: u32 = 0; +pub const PFTM_TS_DIFF_VAL: u32 = 30; +pub const PF_POOL_IDMASK: u32 = 15; +pub const PF_POOL_TYPEMASK: u32 = 15; +pub const PF_POOL_STICKYADDR: u32 = 32; +pub const PF_WSCALE_FLAG: u32 = 128; +pub const PF_WSCALE_MASK: u32 = 15; +pub const PF_LOG: u32 = 1; +pub const PF_LOG_ALL: u32 = 2; +pub const PF_LOG_SOCKET_LOOKUP: u32 = 4; +pub const PF_LOG_FORCE: u32 = 8; +pub const PFRES_MATCH: u32 = 0; +pub const PFRES_BADOFF: u32 = 1; +pub const PFRES_FRAG: u32 = 2; +pub const PFRES_SHORT: u32 = 3; +pub const PFRES_NORM: u32 = 4; +pub const PFRES_MEMORY: u32 = 5; +pub const PFRES_TS: u32 = 6; +pub const PFRES_CONGEST: u32 = 7; +pub const PFRES_IPOPTIONS: u32 = 8; +pub const PFRES_PROTCKSUM: u32 = 9; +pub const PFRES_BADSTATE: u32 = 10; +pub const PFRES_STATEINS: u32 = 11; +pub const PFRES_MAXSTATES: u32 = 12; +pub const PFRES_SRCLIMIT: u32 = 13; +pub const PFRES_SYNPROXY: u32 = 14; +pub const PFRES_MAPFAILED: u32 = 15; +pub const PFRES_MAX: u32 = 16; +pub const LCNT_STATES: u32 = 0; +pub const LCNT_SRCSTATES: u32 = 1; +pub const LCNT_SRCNODES: u32 = 2; +pub const LCNT_SRCCONN: u32 = 3; +pub const LCNT_SRCCONNRATE: u32 = 4; +pub const LCNT_OVERLOAD_TABLE: u32 = 5; +pub const LCNT_OVERLOAD_FLUSH: u32 = 6; +pub const LCNT_MAX: u32 = 7; +pub const KLCNT_SYNFLOODS: u32 = 7; +pub const KLCNT_SYNCOOKIES_SENT: u32 = 8; +pub const KLCNT_SYNCOOKIES_VALID: u32 = 9; +pub const KLCNT_MAX: u32 = 10; +pub const FCNT_STATE_SEARCH: u32 = 0; +pub const FCNT_STATE_INSERT: u32 = 1; +pub const FCNT_STATE_REMOVALS: u32 = 2; +pub const FCNT_MAX: u32 = 3; +pub const SCNT_SRC_NODE_SEARCH: u32 = 0; +pub const SCNT_SRC_NODE_INSERT: u32 = 1; +pub const SCNT_SRC_NODE_REMOVALS: u32 = 2; +pub const SCNT_MAX: u32 = 3; +pub const PF_TABLE_NAME_SIZE: u32 = 32; +pub const PF_QNAME_SIZE: u32 = 64; +pub const PF_REASS_ENABLED: u32 = 1; +pub const PF_REASS_NODF: u32 = 2; +pub const PFI_AFLAG_NETWORK: u32 = 1; +pub const PFI_AFLAG_BROADCAST: u32 = 2; +pub const PFI_AFLAG_PEER: u32 = 4; +pub const PFI_AFLAG_MODEMASK: u32 = 7; +pub const PFI_AFLAG_NOALIAS: u32 = 8; +pub const PF_OSFP_EXPANDED: u32 = 1; +pub const PF_OSFP_GENERIC: u32 = 2; +pub const PF_OSFP_NODETAIL: u32 = 4; +pub const PF_OSFP_LEN: u32 = 32; +pub const _FP_RESERVED_BIT: u32 = 1; +pub const _FP_UNUSED_BITS: u32 = 1; +pub const _FP_CLASS_BITS: u32 = 10; +pub const _FP_VERSION_BITS: u32 = 10; +pub const _FP_SUBTYPE_BITS: u32 = 10; +pub const PF_OSFP_WSIZE_MOD: u32 = 1; +pub const PF_OSFP_WSIZE_DC: u32 = 2; +pub const PF_OSFP_WSIZE_MSS: u32 = 4; +pub const PF_OSFP_WSIZE_MTU: u32 = 8; +pub const PF_OSFP_PSIZE_MOD: u32 = 16; +pub const PF_OSFP_PSIZE_DC: u32 = 32; +pub const PF_OSFP_WSCALE: u32 = 64; +pub const PF_OSFP_WSCALE_MOD: u32 = 128; +pub const PF_OSFP_WSCALE_DC: u32 = 256; +pub const PF_OSFP_MSS: u32 = 512; +pub const PF_OSFP_MSS_MOD: u32 = 1024; +pub const PF_OSFP_MSS_DC: u32 = 2048; +pub const PF_OSFP_DF: u32 = 4096; +pub const PF_OSFP_TS0: u32 = 8192; +pub const PF_OSFP_INET6: u32 = 16384; +pub const PF_OSFP_MAXTTL_OFFSET: u32 = 40; +pub const PF_OSFP_TCPOPT_NOP: u32 = 0; +pub const PF_OSFP_TCPOPT_WSCALE: u32 = 1; +pub const PF_OSFP_TCPOPT_MSS: u32 = 2; +pub const PF_OSFP_TCPOPT_SACK: u32 = 3; +pub const PF_OSFP_TCPOPT_TS: u32 = 4; +pub const PF_OSFP_TCPOPT_BITS: u32 = 3; +pub const PF_ANCHOR_NAME_SIZE: u32 = 64; +pub const PF_SKIP_IFP: u32 = 0; +pub const PF_SKIP_DIR: u32 = 1; +pub const PF_SKIP_AF: u32 = 2; +pub const PF_SKIP_PROTO: u32 = 3; +pub const PF_SKIP_SRC_ADDR: u32 = 4; +pub const PF_SKIP_SRC_PORT: u32 = 5; +pub const PF_SKIP_DST_ADDR: u32 = 6; +pub const PF_SKIP_DST_PORT: u32 = 7; +pub const PF_SKIP_COUNT: u32 = 8; +pub const PF_RULE_LABEL_SIZE: u32 = 64; +pub const PF_RULE_MAX_LABEL_COUNT: u32 = 5; +pub const PF_TAG_NAME_SIZE: u32 = 64; +pub const PF_STATE_NORMAL: u32 = 1; +pub const PF_STATE_MODULATE: u32 = 2; +pub const PF_STATE_SYNPROXY: u32 = 3; +pub const PF_FLUSH: u32 = 1; +pub const PF_FLUSH_GLOBAL: u32 = 2; +pub const PF_PRIO_ZERO: u32 = 255; +pub const PF_PRIO_MAX: u32 = 7; +pub const PFRULE_DROP: u32 = 0; +pub const PFRULE_RETURNRST: u32 = 1; +pub const PFRULE_FRAGMENT: u32 = 2; +pub const PFRULE_RETURNICMP: u32 = 4; +pub const PFRULE_RETURN: u32 = 8; +pub const PFRULE_NOSYNC: u32 = 16; +pub const PFRULE_SRCTRACK: u32 = 32; +pub const PFRULE_RULESRCTRACK: u32 = 64; +pub const PFRULE_NODF: u32 = 256; +pub const PFRULE_FRAGMENT_NOREASS: u32 = 512; +pub const PFRULE_RANDOMID: u32 = 2048; +pub const PFRULE_REASSEMBLE_TCP: u32 = 4096; +pub const PFRULE_SET_TOS: u32 = 8192; +pub const PFRULE_IFBOUND: u32 = 65536; +pub const PFRULE_STATESLOPPY: u32 = 131072; +pub const PFRULE_DN_IS_PIPE: u32 = 64; +pub const PFRULE_DN_IS_QUEUE: u32 = 128; +pub const PFSTATE_ALLOWOPTS: u32 = 1; +pub const PFSTATE_SLOPPY: u32 = 2; +pub const PFSTATE_NOSYNC: u32 = 8; +pub const PFSTATE_ACK: u32 = 16; +pub const PFSTATE_NODF: u32 = 32; +pub const PFSTATE_SETTOS: u32 = 64; +pub const PFSTATE_RANDOMID: u32 = 128; +pub const PFSTATE_SCRUB_TCP: u32 = 256; +pub const PFSTATE_SETPRIO: u32 = 512; +pub const PFSTATE_DN_IS_PIPE: u32 = 16384; +pub const PFSTATE_DN_IS_QUEUE: u32 = 32768; +pub const PFSTATE_SCRUBMASK: u32 = 416; +pub const PFSTATE_SETMASK: u32 = 576; +pub const PFSTATE_HIWAT: u32 = 100000; +pub const PFSTATE_ADAPT_START: u32 = 60000; +pub const PFSTATE_ADAPT_END: u32 = 120000; +pub const PF_THRESHOLD_MULT: u32 = 1000; +pub const PF_THRESHOLD_MAX: u32 = 4294967; +pub const PFSNODE_HIWAT: u32 = 10000; +pub const PFALTQ_FLAG_IF_REMOVED: u32 = 1; +pub const PF_ALTQ_VERSION: u32 = 1; +pub const PFSS_TIMESTAMP: u32 = 1; +pub const PFSS_PAWS: u32 = 16; +pub const PFSS_PAWS_IDLED: u32 = 32; +pub const PFSS_DATA_TS: u32 = 64; +pub const PFSS_DATA_NOTS: u32 = 128; +pub const PF_SCRUB_FLAG_VALID: u32 = 1; +pub const PF_STATE_VERSION: u32 = 20230404; +pub const PFSYNC_SCRUB_FLAG_VALID: u32 = 1; +pub const PFSYNC_FLAG_SRCNODE: u32 = 4; +pub const PFSYNC_FLAG_NATSRCNODE: u32 = 8; +pub const PF_RESERVED_ANCHOR: &[u8; 4] = b"_pf\0"; +pub const PFR_TFLAG_PERSIST: u32 = 1; +pub const PFR_TFLAG_CONST: u32 = 2; +pub const PFR_TFLAG_ACTIVE: u32 = 4; +pub const PFR_TFLAG_INACTIVE: u32 = 8; +pub const PFR_TFLAG_REFERENCED: u32 = 16; +pub const PFR_TFLAG_REFDANCHOR: u32 = 32; +pub const PFR_TFLAG_COUNTERS: u32 = 64; +pub const PFR_TFLAG_USRMASK: u32 = 67; +pub const PFR_TFLAG_SETMASK: u32 = 60; +pub const PFR_TFLAG_ALLMASK: u32 = 127; +pub const PFI_IFLAG_REFS: u32 = 1; +pub const PFI_IFLAG_SKIP: u32 = 256; +pub const PF_DPORT_RANGE: u32 = 1; +pub const PF_RPORT_RANGE: u32 = 2; +pub const PFUDPS_NO_TRAFFIC: u32 = 0; +pub const PFUDPS_SINGLE: u32 = 1; +pub const PFUDPS_MULTIPLE: u32 = 2; +pub const PFUDPS_NSTATES: u32 = 3; +pub const PFOTHERS_NO_TRAFFIC: u32 = 0; +pub const PFOTHERS_SINGLE: u32 = 1; +pub const PFOTHERS_MULTIPLE: u32 = 2; +pub const PFOTHERS_NSTATES: u32 = 3; +pub const PF_SYNCOOKIES_HIWATPCT: u32 = 25; +pub const PF_SYNCOOKIES_LOWATPCT: u32 = 12; +pub const PFFRAG_FRENT_HIWAT: u32 = 5000; +pub const PFR_KENTRY_HIWAT: u32 = 200000; +pub const PF_FRAG_ENTRY_POINTS: u32 = 16; +pub const PF_FRAG_ENTRY_LIMIT: u32 = 64; +pub const PFIOC_ALTQ_VERSION: u32 = 1; +pub const PFIOC_QSTATS_VERSION: u32 = 1; +pub const PFR_FLAG_ATOMIC: u32 = 1; +pub const PFR_FLAG_DUMMY: u32 = 2; +pub const PFR_FLAG_FEEDBACK: u32 = 4; +pub const PFR_FLAG_CLSTATS: u32 = 8; +pub const PFR_FLAG_ADDRSTOO: u32 = 16; +pub const PFR_FLAG_REPLACE: u32 = 32; +pub const PFR_FLAG_ALLRSETS: u32 = 64; +pub const PFR_FLAG_ALLMASK: u32 = 127; +pub const PF_IFSPEED_VERSION: u32 = 1; +pub type __int8_t = ::std::os::raw::c_schar; +pub type __uint8_t = ::std::os::raw::c_uchar; +pub type __int16_t = ::std::os::raw::c_short; +pub type __uint16_t = ::std::os::raw::c_ushort; +pub type __int32_t = ::std::os::raw::c_int; +pub type __uint32_t = ::std::os::raw::c_uint; +pub type __int64_t = ::std::os::raw::c_long; +pub type __uint64_t = ::std::os::raw::c_ulong; +pub type __int_least8_t = __int8_t; +pub type __int_least16_t = __int16_t; +pub type __int_least32_t = __int32_t; +pub type __int_least64_t = __int64_t; +pub type __intmax_t = __int64_t; +pub type __uint_least8_t = __uint8_t; +pub type __uint_least16_t = __uint16_t; +pub type __uint_least32_t = __uint32_t; +pub type __uint_least64_t = __uint64_t; +pub type __uintmax_t = __uint64_t; +pub type __intptr_t = __int64_t; +pub type __intfptr_t = __int64_t; +pub type __uintptr_t = __uint64_t; +pub type __uintfptr_t = __uint64_t; +pub type __vm_offset_t = __uint64_t; +pub type __vm_size_t = __uint64_t; +pub type __size_t = __uint64_t; +pub type __ssize_t = __int64_t; +pub type __ptrdiff_t = __int64_t; +pub type __clock_t = __int32_t; +pub type __critical_t = __int64_t; +pub type __double_t = f64; +pub type __float_t = f32; +pub type __int_fast8_t = __int32_t; +pub type __int_fast16_t = __int32_t; +pub type __int_fast32_t = __int32_t; +pub type __int_fast64_t = __int64_t; +pub type __register_t = __int64_t; +pub type __segsz_t = __int64_t; +pub type __time_t = __int64_t; +pub type __uint_fast8_t = __uint32_t; +pub type __uint_fast16_t = __uint32_t; +pub type __uint_fast32_t = __uint32_t; +pub type __uint_fast64_t = __uint64_t; +pub type __u_register_t = __uint64_t; +pub type __vm_paddr_t = __uint64_t; +pub type ___wchar_t = ::std::os::raw::c_int; +pub type __blksize_t = __int32_t; +pub type __blkcnt_t = __int64_t; +pub type __clockid_t = __int32_t; +pub type __fflags_t = __uint32_t; +pub type __fsblkcnt_t = __uint64_t; +pub type __fsfilcnt_t = __uint64_t; +pub type __gid_t = __uint32_t; +pub type __id_t = __int64_t; +pub type __ino_t = __uint64_t; +pub type __key_t = ::std::os::raw::c_long; +pub type __lwpid_t = __int32_t; +pub type __mode_t = __uint16_t; +pub type __accmode_t = ::std::os::raw::c_int; +pub type __nl_item = ::std::os::raw::c_int; +pub type __nlink_t = __uint64_t; +pub type __off_t = __int64_t; +pub type __off64_t = __int64_t; +pub type __pid_t = __int32_t; +pub type __sbintime_t = __int64_t; +pub type __rlim_t = __int64_t; +pub type __sa_family_t = __uint8_t; +pub type __socklen_t = __uint32_t; +pub type __suseconds_t = ::std::os::raw::c_long; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __timer { + _unused: [u8; 0], +} +pub type __timer_t = *mut __timer; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __mq { + _unused: [u8; 0], +} +pub type __mqd_t = *mut __mq; +pub type __uid_t = __uint32_t; +pub type __useconds_t = ::std::os::raw::c_uint; +pub type __cpuwhich_t = ::std::os::raw::c_int; +pub type __cpulevel_t = ::std::os::raw::c_int; +pub type __cpusetid_t = ::std::os::raw::c_int; +pub type __daddr_t = __int64_t; +pub type __ct_rune_t = ::std::os::raw::c_int; +pub type __rune_t = __ct_rune_t; +pub type __wint_t = __ct_rune_t; +pub type __char16_t = __uint_least16_t; +pub type __char32_t = __uint_least32_t; +#[repr(C)] +#[repr(align(16))] +#[derive(Debug, Copy, Clone)] +pub struct __max_align_t { + pub __max_align1: ::std::os::raw::c_longlong, + pub __bindgen_padding_0: u64, + pub __max_align2: u128, +} +#[test] +fn bindgen_test_layout___max_align_t() { + const UNINIT: ::std::mem::MaybeUninit<__max_align_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__max_align_t>(), + 32usize, + concat!("Size of: ", stringify!(__max_align_t)) + ); + assert_eq!( + ::std::mem::align_of::<__max_align_t>(), + 16usize, + concat!("Alignment of ", stringify!(__max_align_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__max_align1) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__max_align_t), + "::", + stringify!(__max_align1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__max_align2) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__max_align_t), + "::", + stringify!(__max_align2) + ) + ); +} +pub type __dev_t = __uint64_t; +pub type __fixpt_t = __uint32_t; +#[repr(C)] +#[derive(Copy, Clone)] +pub union __mbstate_t { + pub __mbstate8: [::std::os::raw::c_char; 128usize], + pub _mbstateL: __int64_t, +} +#[test] +fn bindgen_test_layout___mbstate_t() { + const UNINIT: ::std::mem::MaybeUninit<__mbstate_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__mbstate_t>(), + 128usize, + concat!("Size of: ", stringify!(__mbstate_t)) + ); + assert_eq!( + ::std::mem::align_of::<__mbstate_t>(), + 8usize, + concat!("Alignment of ", stringify!(__mbstate_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__mbstate8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__mbstate_t), + "::", + stringify!(__mbstate8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._mbstateL) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__mbstate_t), + "::", + stringify!(_mbstateL) + ) + ); +} +pub type __rman_res_t = __uintmax_t; +pub type __va_list = __builtin_va_list; +pub type __gnuc_va_list = __va_list; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_attr { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_cond { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_cond_attr { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_mutex { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_mutex_attr { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_rwlock { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_rwlockattr { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_barrier { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_barrier_attr { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_spinlock { + _unused: [u8; 0], +} +pub type pthread_t = *mut pthread; +pub type pthread_attr_t = *mut pthread_attr; +pub type pthread_mutex_t = *mut pthread_mutex; +pub type pthread_mutexattr_t = *mut pthread_mutex_attr; +pub type pthread_cond_t = *mut pthread_cond; +pub type pthread_condattr_t = *mut pthread_cond_attr; +pub type pthread_key_t = ::std::os::raw::c_int; +pub type pthread_once_t = pthread_once; +pub type pthread_rwlock_t = *mut pthread_rwlock; +pub type pthread_rwlockattr_t = *mut pthread_rwlockattr; +pub type pthread_barrier_t = *mut pthread_barrier; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_barrierattr { + _unused: [u8; 0], +} +pub type pthread_barrierattr_t = *mut pthread_barrierattr; +pub type pthread_spinlock_t = *mut pthread_spinlock; +pub type pthread_addr_t = *mut ::std::os::raw::c_void; +pub type pthread_startroutine_t = + ::std::option::Option *mut ::std::os::raw::c_void>; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pthread_once { + pub state: ::std::os::raw::c_int, + pub mutex: pthread_mutex_t, +} +#[test] +fn bindgen_test_layout_pthread_once() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pthread_once)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_once)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pthread_once), "::", stringify!(state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mutex) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pthread_once), "::", stringify!(mutex)) + ); +} +pub type u_char = ::std::os::raw::c_uchar; +pub type u_short = ::std::os::raw::c_ushort; +pub type u_int = ::std::os::raw::c_uint; +pub type u_long = ::std::os::raw::c_ulong; +pub type ushort = ::std::os::raw::c_ushort; +pub type uint = ::std::os::raw::c_uint; +pub type intmax_t = __intmax_t; +pub type uintmax_t = __uintmax_t; +pub type u_int8_t = __uint8_t; +pub type u_int16_t = __uint16_t; +pub type u_int32_t = __uint32_t; +pub type u_int64_t = __uint64_t; +pub type u_quad_t = __uint64_t; +pub type quad_t = __int64_t; +pub type qaddr_t = *mut quad_t; +pub type caddr_t = *mut ::std::os::raw::c_char; +pub type c_caddr_t = *const ::std::os::raw::c_char; +pub type blksize_t = __blksize_t; +pub type cpuwhich_t = __cpuwhich_t; +pub type cpulevel_t = __cpulevel_t; +pub type cpusetid_t = __cpusetid_t; +pub type blkcnt_t = __blkcnt_t; +pub type clock_t = __clock_t; +pub type clockid_t = __clockid_t; +pub type critical_t = __critical_t; +pub type daddr_t = __daddr_t; +pub type dev_t = __dev_t; +pub type fflags_t = __fflags_t; +pub type fixpt_t = __fixpt_t; +pub type fsblkcnt_t = __fsblkcnt_t; +pub type fsfilcnt_t = __fsfilcnt_t; +pub type gid_t = __gid_t; +pub type in_addr_t = __uint32_t; +pub type in_port_t = __uint16_t; +pub type id_t = __id_t; +pub type ino_t = __ino_t; +pub type key_t = __key_t; +pub type lwpid_t = __lwpid_t; +pub type mode_t = __mode_t; +pub type accmode_t = __accmode_t; +pub type nlink_t = __nlink_t; +pub type off_t = __off_t; +pub type off64_t = __off64_t; +pub type pid_t = __pid_t; +pub type register_t = __register_t; +pub type rlim_t = __rlim_t; +pub type sbintime_t = __sbintime_t; +pub type segsz_t = __segsz_t; +pub type suseconds_t = __suseconds_t; +pub type time_t = __time_t; +pub type timer_t = __timer_t; +pub type mqd_t = __mqd_t; +pub type u_register_t = __u_register_t; +pub type uid_t = __uid_t; +pub type useconds_t = __useconds_t; +pub type cap_ioctl_t = ::std::os::raw::c_ulong; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct cap_rights { + _unused: [u8; 0], +} +pub type cap_rights_t = cap_rights; +pub type kpaddr_t = __uint64_t; +pub type kvaddr_t = __uint64_t; +pub type ksize_t = __uint64_t; +pub type kssize_t = __int64_t; +pub type vm_offset_t = __vm_offset_t; +pub type vm_ooffset_t = __uint64_t; +pub type vm_paddr_t = __vm_paddr_t; +pub type vm_pindex_t = __uint64_t; +pub type vm_size_t = __vm_size_t; +pub type rman_res_t = __rman_res_t; +pub type syscallarg_t = __register_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __sigset { + pub __bits: [__uint32_t; 4usize], +} +#[test] +fn bindgen_test_layout___sigset() { + const UNINIT: ::std::mem::MaybeUninit<__sigset> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__sigset>(), + 16usize, + concat!("Size of: ", stringify!(__sigset)) + ); + assert_eq!( + ::std::mem::align_of::<__sigset>(), + 4usize, + concat!("Alignment of ", stringify!(__sigset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__bits) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(__sigset), "::", stringify!(__bits)) + ); +} +pub type __sigset_t = __sigset; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timeval { + pub tv_sec: time_t, + pub tv_usec: suseconds_t, +} +#[test] +fn bindgen_test_layout_timeval() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timeval)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(timeval)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(timeval), "::", stringify!(tv_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_usec) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(timeval), "::", stringify!(tv_usec)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timespec { + pub tv_sec: time_t, + pub tv_nsec: ::std::os::raw::c_long, +} +#[test] +fn bindgen_test_layout_timespec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timespec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(timespec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(timespec), "::", stringify!(tv_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_nsec) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(timespec), "::", stringify!(tv_nsec)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct itimerspec { + pub it_interval: timespec, + pub it_value: timespec, +} +#[test] +fn bindgen_test_layout_itimerspec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(itimerspec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(itimerspec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_interval) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(itimerspec), + "::", + stringify!(it_interval) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_value) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(itimerspec), "::", stringify!(it_value)) + ); +} +pub type __fd_mask = ::std::os::raw::c_ulong; +pub type fd_mask = __fd_mask; +pub type sigset_t = __sigset_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct fd_set { + pub __fds_bits: [__fd_mask; 16usize], +} +#[test] +fn bindgen_test_layout_fd_set() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(fd_set)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(fd_set)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fds_bits) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(fd_set), "::", stringify!(__fds_bits)) + ); +} +extern "C" { + pub fn pselect( + arg1: ::std::os::raw::c_int, + arg2: *mut fd_set, + arg3: *mut fd_set, + arg4: *mut fd_set, + arg5: *const timespec, + arg6: *const sigset_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn select( + arg1: ::std::os::raw::c_int, + arg2: *mut fd_set, + arg3: *mut fd_set, + arg4: *mut fd_set, + arg5: *mut timeval, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ftruncate(arg1: ::std::os::raw::c_int, arg2: off_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn lseek(arg1: ::std::os::raw::c_int, arg2: off_t, arg3: ::std::os::raw::c_int) -> off_t; +} +extern "C" { + pub fn mmap( + arg1: *mut ::std::os::raw::c_void, + arg2: usize, + arg3: ::std::os::raw::c_int, + arg4: ::std::os::raw::c_int, + arg5: ::std::os::raw::c_int, + arg6: off_t, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn truncate(arg1: *const ::std::os::raw::c_char, arg2: off_t) -> ::std::os::raw::c_int; +} +pub type sig_atomic_t = ::std::os::raw::c_long; +#[repr(C)] +#[repr(align(16))] +#[derive(Debug, Copy, Clone)] +pub struct sigcontext { + pub sc_mask: __sigset, + pub sc_onstack: ::std::os::raw::c_long, + pub sc_rdi: ::std::os::raw::c_long, + pub sc_rsi: ::std::os::raw::c_long, + pub sc_rdx: ::std::os::raw::c_long, + pub sc_rcx: ::std::os::raw::c_long, + pub sc_r8: ::std::os::raw::c_long, + pub sc_r9: ::std::os::raw::c_long, + pub sc_rax: ::std::os::raw::c_long, + pub sc_rbx: ::std::os::raw::c_long, + pub sc_rbp: ::std::os::raw::c_long, + pub sc_r10: ::std::os::raw::c_long, + pub sc_r11: ::std::os::raw::c_long, + pub sc_r12: ::std::os::raw::c_long, + pub sc_r13: ::std::os::raw::c_long, + pub sc_r14: ::std::os::raw::c_long, + pub sc_r15: ::std::os::raw::c_long, + pub sc_trapno: ::std::os::raw::c_int, + pub sc_fs: ::std::os::raw::c_short, + pub sc_gs: ::std::os::raw::c_short, + pub sc_addr: ::std::os::raw::c_long, + pub sc_flags: ::std::os::raw::c_int, + pub sc_es: ::std::os::raw::c_short, + pub sc_ds: ::std::os::raw::c_short, + pub sc_err: ::std::os::raw::c_long, + pub sc_rip: ::std::os::raw::c_long, + pub sc_cs: ::std::os::raw::c_long, + pub sc_rflags: ::std::os::raw::c_long, + pub sc_rsp: ::std::os::raw::c_long, + pub sc_ss: ::std::os::raw::c_long, + pub sc_len: ::std::os::raw::c_long, + pub sc_fpformat: ::std::os::raw::c_long, + pub sc_ownedfp: ::std::os::raw::c_long, + pub sc_fpstate: [::std::os::raw::c_long; 64usize], + pub sc_fsbase: ::std::os::raw::c_long, + pub sc_gsbase: ::std::os::raw::c_long, + pub sc_xfpustate: ::std::os::raw::c_long, + pub sc_xfpustate_len: ::std::os::raw::c_long, + pub sc_spare: [::std::os::raw::c_long; 4usize], +} +#[test] +fn bindgen_test_layout_sigcontext() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 816usize, + concat!("Size of: ", stringify!(sigcontext)) + ); + assert_eq!( + ::std::mem::align_of::(), + 16usize, + concat!("Alignment of ", stringify!(sigcontext)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_mask) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_onstack) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(sigcontext), + "::", + stringify!(sc_onstack) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rdi) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rdi)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rsi) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rsi)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rdx) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rdx)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rcx) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rcx)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_r8) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_r8)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_r9) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_r9)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rax) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rax)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rbx) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rbx)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rbp) as usize - ptr as usize }, + 88usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rbp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_r10) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_r10)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_r11) as usize - ptr as usize }, + 104usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_r11)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_r12) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_r12)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_r13) as usize - ptr as usize }, + 120usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_r13)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_r14) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_r14)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_r15) as usize - ptr as usize }, + 136usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_r15)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_trapno) as usize - ptr as usize }, + 144usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_trapno)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_fs) as usize - ptr as usize }, + 148usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_fs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_gs) as usize - ptr as usize }, + 150usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_gs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_addr) as usize - ptr as usize }, + 152usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_flags) as usize - ptr as usize }, + 160usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_es) as usize - ptr as usize }, + 164usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_es)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_ds) as usize - ptr as usize }, + 166usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_ds)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_err) as usize - ptr as usize }, + 168usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_err)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rip) as usize - ptr as usize }, + 176usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rip)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_cs) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_cs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rflags) as usize - ptr as usize }, + 192usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rflags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_rsp) as usize - ptr as usize }, + 200usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_rsp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_ss) as usize - ptr as usize }, + 208usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_ss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_len) as usize - ptr as usize }, + 216usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_fpformat) as usize - ptr as usize }, + 224usize, + concat!( + "Offset of field: ", + stringify!(sigcontext), + "::", + stringify!(sc_fpformat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_ownedfp) as usize - ptr as usize }, + 232usize, + concat!( + "Offset of field: ", + stringify!(sigcontext), + "::", + stringify!(sc_ownedfp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_fpstate) as usize - ptr as usize }, + 240usize, + concat!( + "Offset of field: ", + stringify!(sigcontext), + "::", + stringify!(sc_fpstate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_fsbase) as usize - ptr as usize }, + 752usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_fsbase)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_gsbase) as usize - ptr as usize }, + 760usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_gsbase)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_xfpustate) as usize - ptr as usize }, + 768usize, + concat!( + "Offset of field: ", + stringify!(sigcontext), + "::", + stringify!(sc_xfpustate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_xfpustate_len) as usize - ptr as usize }, + 776usize, + concat!( + "Offset of field: ", + stringify!(sigcontext), + "::", + stringify!(sc_xfpustate_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_spare) as usize - ptr as usize }, + 784usize, + concat!("Offset of field: ", stringify!(sigcontext), "::", stringify!(sc_spare)) + ); +} +pub type __sighandler_t = ::std::option::Option; +#[repr(C)] +#[derive(Copy, Clone)] +pub union sigval { + pub sival_int: ::std::os::raw::c_int, + pub sival_ptr: *mut ::std::os::raw::c_void, + pub sigval_int: ::std::os::raw::c_int, + pub sigval_ptr: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout_sigval() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(sigval)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigval)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sival_int) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigval), "::", stringify!(sival_int)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sival_ptr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigval), "::", stringify!(sival_ptr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigval_int) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigval), "::", stringify!(sigval_int)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigval_ptr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigval), "::", stringify!(sigval_ptr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct sigevent { + pub sigev_notify: ::std::os::raw::c_int, + pub sigev_signo: ::std::os::raw::c_int, + pub sigev_value: sigval, + pub _sigev_un: sigevent__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union sigevent__bindgen_ty_1 { + pub _threadid: __lwpid_t, + pub _sigev_thread: sigevent__bindgen_ty_1__bindgen_ty_1, + pub _kevent_flags: ::std::os::raw::c_ushort, + pub __spare__: [::std::os::raw::c_long; 8usize], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sigevent__bindgen_ty_1__bindgen_ty_1 { + pub _function: ::std::option::Option, + pub _attribute: *mut *mut pthread_attr, +} +#[test] +fn bindgen_test_layout_sigevent__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sigevent__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigevent__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._function) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigevent__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(_function) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._attribute) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sigevent__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(_attribute) + ) + ); +} +#[test] +fn bindgen_test_layout_sigevent__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(sigevent__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigevent__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._threadid) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigevent__bindgen_ty_1), + "::", + stringify!(_threadid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._sigev_thread) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigevent__bindgen_ty_1), + "::", + stringify!(_sigev_thread) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._kevent_flags) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigevent__bindgen_ty_1), + "::", + stringify!(_kevent_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__spare__) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigevent__bindgen_ty_1), + "::", + stringify!(__spare__) + ) + ); +} +#[test] +fn bindgen_test_layout_sigevent() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 80usize, + concat!("Size of: ", stringify!(sigevent)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigevent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigev_notify) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigevent), + "::", + stringify!(sigev_notify) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigev_signo) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(sigevent), "::", stringify!(sigev_signo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigev_value) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sigevent), "::", stringify!(sigev_value)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._sigev_un) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(sigevent), "::", stringify!(_sigev_un)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct __siginfo { + pub si_signo: ::std::os::raw::c_int, + pub si_errno: ::std::os::raw::c_int, + pub si_code: ::std::os::raw::c_int, + pub si_pid: __pid_t, + pub si_uid: __uid_t, + pub si_status: ::std::os::raw::c_int, + pub si_addr: *mut ::std::os::raw::c_void, + pub si_value: sigval, + pub _reason: __siginfo__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union __siginfo__bindgen_ty_1 { + pub _fault: __siginfo__bindgen_ty_1__bindgen_ty_1, + pub _timer: __siginfo__bindgen_ty_1__bindgen_ty_2, + pub _mesgq: __siginfo__bindgen_ty_1__bindgen_ty_3, + pub _poll: __siginfo__bindgen_ty_1__bindgen_ty_4, + pub _capsicum: __siginfo__bindgen_ty_1__bindgen_ty_5, + pub __spare__: __siginfo__bindgen_ty_1__bindgen_ty_6, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __siginfo__bindgen_ty_1__bindgen_ty_1 { + pub _trapno: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___siginfo__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit<__siginfo__bindgen_ty_1__bindgen_ty_1> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__siginfo__bindgen_ty_1__bindgen_ty_1>(), + 4usize, + concat!("Size of: ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::<__siginfo__bindgen_ty_1__bindgen_ty_1>(), + 4usize, + concat!("Alignment of ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._trapno) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(_trapno) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __siginfo__bindgen_ty_1__bindgen_ty_2 { + pub _timerid: ::std::os::raw::c_int, + pub _overrun: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___siginfo__bindgen_ty_1__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit<__siginfo__bindgen_ty_1__bindgen_ty_2> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__siginfo__bindgen_ty_1__bindgen_ty_2>(), + 8usize, + concat!("Size of: ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::<__siginfo__bindgen_ty_1__bindgen_ty_2>(), + 4usize, + concat!("Alignment of ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._timerid) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(_timerid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._overrun) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(_overrun) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __siginfo__bindgen_ty_1__bindgen_ty_3 { + pub _mqd: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___siginfo__bindgen_ty_1__bindgen_ty_3() { + const UNINIT: ::std::mem::MaybeUninit<__siginfo__bindgen_ty_1__bindgen_ty_3> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__siginfo__bindgen_ty_1__bindgen_ty_3>(), + 4usize, + concat!("Size of: ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_3)) + ); + assert_eq!( + ::std::mem::align_of::<__siginfo__bindgen_ty_1__bindgen_ty_3>(), + 4usize, + concat!("Alignment of ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_3)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._mqd) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1__bindgen_ty_3), + "::", + stringify!(_mqd) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __siginfo__bindgen_ty_1__bindgen_ty_4 { + pub _band: ::std::os::raw::c_long, +} +#[test] +fn bindgen_test_layout___siginfo__bindgen_ty_1__bindgen_ty_4() { + const UNINIT: ::std::mem::MaybeUninit<__siginfo__bindgen_ty_1__bindgen_ty_4> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__siginfo__bindgen_ty_1__bindgen_ty_4>(), + 8usize, + concat!("Size of: ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_4)) + ); + assert_eq!( + ::std::mem::align_of::<__siginfo__bindgen_ty_1__bindgen_ty_4>(), + 8usize, + concat!("Alignment of ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_4)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._band) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1__bindgen_ty_4), + "::", + stringify!(_band) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __siginfo__bindgen_ty_1__bindgen_ty_5 { + pub _syscall: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___siginfo__bindgen_ty_1__bindgen_ty_5() { + const UNINIT: ::std::mem::MaybeUninit<__siginfo__bindgen_ty_1__bindgen_ty_5> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__siginfo__bindgen_ty_1__bindgen_ty_5>(), + 4usize, + concat!("Size of: ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_5)) + ); + assert_eq!( + ::std::mem::align_of::<__siginfo__bindgen_ty_1__bindgen_ty_5>(), + 4usize, + concat!("Alignment of ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_5)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._syscall) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1__bindgen_ty_5), + "::", + stringify!(_syscall) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __siginfo__bindgen_ty_1__bindgen_ty_6 { + pub __spare1__: ::std::os::raw::c_long, + pub __spare2__: [::std::os::raw::c_int; 7usize], +} +#[test] +fn bindgen_test_layout___siginfo__bindgen_ty_1__bindgen_ty_6() { + const UNINIT: ::std::mem::MaybeUninit<__siginfo__bindgen_ty_1__bindgen_ty_6> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__siginfo__bindgen_ty_1__bindgen_ty_6>(), + 40usize, + concat!("Size of: ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_6)) + ); + assert_eq!( + ::std::mem::align_of::<__siginfo__bindgen_ty_1__bindgen_ty_6>(), + 8usize, + concat!("Alignment of ", stringify!(__siginfo__bindgen_ty_1__bindgen_ty_6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__spare1__) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1__bindgen_ty_6), + "::", + stringify!(__spare1__) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__spare2__) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1__bindgen_ty_6), + "::", + stringify!(__spare2__) + ) + ); +} +#[test] +fn bindgen_test_layout___siginfo__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit<__siginfo__bindgen_ty_1> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__siginfo__bindgen_ty_1>(), + 40usize, + concat!("Size of: ", stringify!(__siginfo__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::<__siginfo__bindgen_ty_1>(), + 8usize, + concat!("Alignment of ", stringify!(__siginfo__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._fault) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1), + "::", + stringify!(_fault) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._timer) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1), + "::", + stringify!(_timer) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._mesgq) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1), + "::", + stringify!(_mesgq) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._poll) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1), + "::", + stringify!(_poll) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._capsicum) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1), + "::", + stringify!(_capsicum) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__spare__) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__siginfo__bindgen_ty_1), + "::", + stringify!(__spare__) + ) + ); +} +#[test] +fn bindgen_test_layout___siginfo() { + const UNINIT: ::std::mem::MaybeUninit<__siginfo> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__siginfo>(), + 80usize, + concat!("Size of: ", stringify!(__siginfo)) + ); + assert_eq!( + ::std::mem::align_of::<__siginfo>(), + 8usize, + concat!("Alignment of ", stringify!(__siginfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_signo) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_signo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_errno) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_errno)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_code) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_code)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_pid) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_pid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_uid) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_status) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_status)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_addr) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_value) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_value)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._reason) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(_reason)) + ); +} +pub type siginfo_t = __siginfo; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct sigaction { + pub __sigaction_u: sigaction__bindgen_ty_1, + pub sa_flags: ::std::os::raw::c_int, + pub sa_mask: sigset_t, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union sigaction__bindgen_ty_1 { + pub __sa_handler: ::std::option::Option, + pub __sa_sigaction: ::std::option::Option< + unsafe extern "C" fn(arg1: ::std::os::raw::c_int, arg2: *mut __siginfo, arg3: *mut ::std::os::raw::c_void), + >, +} +#[test] +fn bindgen_test_layout_sigaction__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(sigaction__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigaction__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sa_handler) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigaction__bindgen_ty_1), + "::", + stringify!(__sa_handler) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sa_sigaction) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigaction__bindgen_ty_1), + "::", + stringify!(__sa_sigaction) + ) + ); +} +#[test] +fn bindgen_test_layout_sigaction() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(sigaction)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigaction)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sigaction_u) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigaction), + "::", + stringify!(__sigaction_u) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_flags) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sigaction), "::", stringify!(sa_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_mask) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(sigaction), "::", stringify!(sa_mask)) + ); +} +pub type sig_t = __sighandler_t; +pub type __siginfohandler_t = ::std::option::Option< + unsafe extern "C" fn(arg1: ::std::os::raw::c_int, arg2: *mut __siginfo, arg3: *mut ::std::os::raw::c_void), +>; +pub type stack_t = sigaltstack; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sigaltstack { + pub ss_sp: *mut ::std::os::raw::c_void, + pub ss_size: __size_t, + pub ss_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_sigaltstack() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(sigaltstack)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigaltstack)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_sp) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigaltstack), "::", stringify!(ss_sp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_size) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sigaltstack), "::", stringify!(ss_size)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_flags) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(sigaltstack), "::", stringify!(ss_flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sigvec { + pub sv_handler: __sighandler_t, + pub sv_mask: ::std::os::raw::c_int, + pub sv_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_sigvec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sigvec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigvec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sv_handler) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigvec), "::", stringify!(sv_handler)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sv_mask) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sigvec), "::", stringify!(sv_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sv_flags) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(sigvec), "::", stringify!(sv_flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sigstack { + pub ss_sp: *mut ::std::os::raw::c_void, + pub ss_onstack: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_sigstack() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sigstack)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigstack)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_sp) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigstack), "::", stringify!(ss_sp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_onstack) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sigstack), "::", stringify!(ss_onstack)) + ); +} +extern "C" { + pub fn signal(arg1: ::std::os::raw::c_int, arg2: __sighandler_t) -> __sighandler_t; +} +pub type counter_u64_t = *mut u64; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _cpuset { + pub __bits: [::std::os::raw::c_long; 16usize], +} +#[test] +fn bindgen_test_layout__cpuset() { + const UNINIT: ::std::mem::MaybeUninit<_cpuset> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_cpuset>(), + 128usize, + concat!("Size of: ", stringify!(_cpuset)) + ); + assert_eq!( + ::std::mem::align_of::<_cpuset>(), + 8usize, + concat!("Alignment of ", stringify!(_cpuset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__bits) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(_cpuset), "::", stringify!(__bits)) + ); +} +pub type cpuset_t = _cpuset; +extern "C" { + pub fn __cpuset_alloc(set_size: usize) -> *mut cpuset_t; +} +extern "C" { + pub fn __cpuset_free(ptr: *mut cpuset_t); +} +extern "C" { + pub fn cpuset(arg1: *mut cpusetid_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn cpuset_setid(arg1: cpuwhich_t, arg2: id_t, arg3: cpusetid_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn cpuset_getid(arg1: cpulevel_t, arg2: cpuwhich_t, arg3: id_t, arg4: *mut cpusetid_t) + -> ::std::os::raw::c_int; +} +extern "C" { + pub fn cpuset_getaffinity( + arg1: cpulevel_t, + arg2: cpuwhich_t, + arg3: id_t, + arg4: usize, + arg5: *mut cpuset_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn cpuset_setaffinity( + arg1: cpulevel_t, + arg2: cpuwhich_t, + arg3: id_t, + arg4: usize, + arg5: *const cpuset_t, + ) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct epoch_context { + pub data: [*mut ::std::os::raw::c_void; 2usize], +} +#[test] +fn bindgen_test_layout_epoch_context() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(epoch_context)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(epoch_context)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).data) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(epoch_context), "::", stringify!(data)) + ); +} +pub type epoch_context_t = *mut epoch_context; +pub type epoch_callback_t = ::std::option::Option; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct lock_object { + pub lo_name: *const ::std::os::raw::c_char, + pub lo_flags: u_int, + pub lo_data: u_int, + pub lo_witness: *mut witness, +} +#[test] +fn bindgen_test_layout_lock_object() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(lock_object)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(lock_object)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lo_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(lock_object), "::", stringify!(lo_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lo_flags) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(lock_object), "::", stringify!(lo_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lo_data) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(lock_object), "::", stringify!(lo_data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lo_witness) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(lock_object), + "::", + stringify!(lo_witness) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct mtx { + pub lock_object: lock_object, + pub mtx_lock: usize, +} +#[test] +fn bindgen_test_layout_mtx() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(mtx)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(mtx)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lock_object) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(mtx), "::", stringify!(lock_object)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mtx_lock) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(mtx), "::", stringify!(mtx_lock)) + ); +} +#[repr(C)] +#[repr(align(64))] +#[derive(Debug, Copy, Clone)] +pub struct mtx_padalign { + pub lock_object: lock_object, + pub mtx_lock: usize, +} +#[test] +fn bindgen_test_layout_mtx_padalign() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(mtx_padalign)) + ); + assert_eq!( + ::std::mem::align_of::(), + 64usize, + concat!("Alignment of ", stringify!(mtx_padalign)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lock_object) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(mtx_padalign), + "::", + stringify!(lock_object) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mtx_lock) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(mtx_padalign), + "::", + stringify!(mtx_lock) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct malloc_type_stats { + pub mts_memalloced: u64, + pub mts_memfreed: u64, + pub mts_numallocs: u64, + pub mts_numfrees: u64, + pub mts_size: u64, + pub _mts_reserved1: u64, + pub _mts_reserved2: u64, + pub _mts_reserved3: u64, +} +#[test] +fn bindgen_test_layout_malloc_type_stats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(malloc_type_stats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(malloc_type_stats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mts_memalloced) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stats), + "::", + stringify!(mts_memalloced) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mts_memfreed) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stats), + "::", + stringify!(mts_memfreed) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mts_numallocs) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stats), + "::", + stringify!(mts_numallocs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mts_numfrees) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stats), + "::", + stringify!(mts_numfrees) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mts_size) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stats), + "::", + stringify!(mts_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._mts_reserved1) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stats), + "::", + stringify!(_mts_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._mts_reserved2) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stats), + "::", + stringify!(_mts_reserved2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._mts_reserved3) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stats), + "::", + stringify!(_mts_reserved3) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct malloc_type_internal { + pub mti_probes: [u32; 2usize], + pub mti_zone: u_char, + pub mti_stats: *mut malloc_type_stats, + pub mti_spare: [u_long; 8usize], +} +#[test] +fn bindgen_test_layout_malloc_type_internal() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 88usize, + concat!("Size of: ", stringify!(malloc_type_internal)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(malloc_type_internal)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mti_probes) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_internal), + "::", + stringify!(mti_probes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mti_zone) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_internal), + "::", + stringify!(mti_zone) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mti_stats) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_internal), + "::", + stringify!(mti_stats) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mti_spare) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_internal), + "::", + stringify!(mti_spare) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct malloc_type { + pub ks_next: *mut malloc_type, + pub ks_version: u_long, + pub ks_shortdesc: *const ::std::os::raw::c_char, + pub ks_mti: malloc_type_internal, +} +#[test] +fn bindgen_test_layout_malloc_type() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 112usize, + concat!("Size of: ", stringify!(malloc_type)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(malloc_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ks_next) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(malloc_type), "::", stringify!(ks_next)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ks_version) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(malloc_type), + "::", + stringify!(ks_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ks_shortdesc) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(malloc_type), + "::", + stringify!(ks_shortdesc) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ks_mti) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(malloc_type), "::", stringify!(ks_mti)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct malloc_type_stream_header { + pub mtsh_version: u32, + pub mtsh_maxcpus: u32, + pub mtsh_count: u32, + pub _mtsh_pad: u32, +} +#[test] +fn bindgen_test_layout_malloc_type_stream_header() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(malloc_type_stream_header)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(malloc_type_stream_header)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mtsh_version) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stream_header), + "::", + stringify!(mtsh_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mtsh_maxcpus) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stream_header), + "::", + stringify!(mtsh_maxcpus) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mtsh_count) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stream_header), + "::", + stringify!(mtsh_count) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._mtsh_pad) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_stream_header), + "::", + stringify!(_mtsh_pad) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct malloc_type_header { + pub mth_name: [::std::os::raw::c_char; 32usize], +} +#[test] +fn bindgen_test_layout_malloc_type_header() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(malloc_type_header)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(malloc_type_header)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mth_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(malloc_type_header), + "::", + stringify!(mth_name) + ) + ); +} +pub type va_list = __va_list; +pub type int_least8_t = __int_least8_t; +pub type int_least16_t = __int_least16_t; +pub type int_least32_t = __int_least32_t; +pub type int_least64_t = __int_least64_t; +pub type uint_least8_t = __uint_least8_t; +pub type uint_least16_t = __uint_least16_t; +pub type uint_least32_t = __uint_least32_t; +pub type uint_least64_t = __uint_least64_t; +pub type int_fast8_t = __int_fast8_t; +pub type int_fast16_t = __int_fast16_t; +pub type int_fast32_t = __int_fast32_t; +pub type int_fast64_t = __int_fast64_t; +pub type uint_fast8_t = __uint_fast8_t; +pub type uint_fast16_t = __uint_fast16_t; +pub type uint_fast32_t = __uint_fast32_t; +pub type uint_fast64_t = __uint_fast64_t; +pub type fpos_t = __off_t; +pub type rsize_t = usize; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __sbuf { + pub _base: *mut ::std::os::raw::c_uchar, + pub _size: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___sbuf() { + const UNINIT: ::std::mem::MaybeUninit<__sbuf> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__sbuf>(), + 16usize, + concat!("Size of: ", stringify!(__sbuf)) + ); + assert_eq!( + ::std::mem::align_of::<__sbuf>(), + 8usize, + concat!("Alignment of ", stringify!(__sbuf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._base) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(__sbuf), "::", stringify!(_base)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._size) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(__sbuf), "::", stringify!(_size)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct __sFILE { + pub _p: *mut ::std::os::raw::c_uchar, + pub _r: ::std::os::raw::c_int, + pub _w: ::std::os::raw::c_int, + pub _flags: ::std::os::raw::c_short, + pub _file: ::std::os::raw::c_short, + pub _bf: __sbuf, + pub _lbfsize: ::std::os::raw::c_int, + pub _cookie: *mut ::std::os::raw::c_void, + pub _close: ::std::option::Option ::std::os::raw::c_int>, + pub _read: ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_char, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int, + >, + pub _seek: ::std::option::Option< + unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void, arg2: fpos_t, arg3: ::std::os::raw::c_int) -> fpos_t, + >, + pub _write: ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_char, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int, + >, + pub _ub: __sbuf, + pub _up: *mut ::std::os::raw::c_uchar, + pub _ur: ::std::os::raw::c_int, + pub _ubuf: [::std::os::raw::c_uchar; 3usize], + pub _nbuf: [::std::os::raw::c_uchar; 1usize], + pub _lb: __sbuf, + pub _blksize: ::std::os::raw::c_int, + pub _offset: fpos_t, + pub _fl_mutex: *mut pthread_mutex, + pub _fl_owner: *mut pthread, + pub _fl_count: ::std::os::raw::c_int, + pub _orientation: ::std::os::raw::c_int, + pub _mbstate: __mbstate_t, + pub _flags2: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___sFILE() { + const UNINIT: ::std::mem::MaybeUninit<__sFILE> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__sFILE>(), + 312usize, + concat!("Size of: ", stringify!(__sFILE)) + ); + assert_eq!( + ::std::mem::align_of::<__sFILE>(), + 8usize, + concat!("Alignment of ", stringify!(__sFILE)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._p) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_p)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._r) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_r)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._w) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_w)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._flags) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._file) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_file)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._bf) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_bf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._lbfsize) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_lbfsize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._cookie) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_cookie)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._close) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_close)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._read) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_read)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._seek) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_seek)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._write) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_write)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ub) as usize - ptr as usize }, + 88usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_ub)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._up) as usize - ptr as usize }, + 104usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_up)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ur) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_ur)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ubuf) as usize - ptr as usize }, + 116usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_ubuf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._nbuf) as usize - ptr as usize }, + 119usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_nbuf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._lb) as usize - ptr as usize }, + 120usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_lb)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._blksize) as usize - ptr as usize }, + 136usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_blksize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._offset) as usize - ptr as usize }, + 144usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_offset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._fl_mutex) as usize - ptr as usize }, + 152usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_fl_mutex)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._fl_owner) as usize - ptr as usize }, + 160usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_fl_owner)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._fl_count) as usize - ptr as usize }, + 168usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_fl_count)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._orientation) as usize - ptr as usize }, + 172usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_orientation)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._mbstate) as usize - ptr as usize }, + 176usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_mbstate)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._flags2) as usize - ptr as usize }, + 304usize, + concat!("Offset of field: ", stringify!(__sFILE), "::", stringify!(_flags2)) + ); +} +pub type FILE = __sFILE; +extern "C" { + pub static mut __stdinp: *mut FILE; +} +extern "C" { + pub static mut __stdoutp: *mut FILE; +} +extern "C" { + pub static mut __stderrp: *mut FILE; +} +extern "C" { + pub fn clearerr(arg1: *mut FILE); +} +extern "C" { + pub fn fclose(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn feof(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ferror(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fflush(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fgetc(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fgetpos(arg1: *mut FILE, arg2: *mut fpos_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fgets( + arg1: *mut ::std::os::raw::c_char, + arg2: ::std::os::raw::c_int, + arg3: *mut FILE, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn fopen(arg1: *const ::std::os::raw::c_char, arg2: *const ::std::os::raw::c_char) -> *mut FILE; +} +extern "C" { + pub fn fprintf(arg1: *mut FILE, arg2: *const ::std::os::raw::c_char, ...) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fputc(arg1: ::std::os::raw::c_int, arg2: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fputs(arg1: *const ::std::os::raw::c_char, arg2: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fread( + arg1: *mut ::std::os::raw::c_void, + arg2: ::std::os::raw::c_ulong, + arg3: ::std::os::raw::c_ulong, + arg4: *mut FILE, + ) -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn freopen( + arg1: *const ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + arg3: *mut FILE, + ) -> *mut FILE; +} +extern "C" { + pub fn fscanf(arg1: *mut FILE, arg2: *const ::std::os::raw::c_char, ...) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fseek(arg1: *mut FILE, arg2: ::std::os::raw::c_long, arg3: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fsetpos(arg1: *mut FILE, arg2: *const fpos_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ftell(arg1: *mut FILE) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn fwrite( + arg1: *const ::std::os::raw::c_void, + arg2: ::std::os::raw::c_ulong, + arg3: ::std::os::raw::c_ulong, + arg4: *mut FILE, + ) -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn getc(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getchar() -> ::std::os::raw::c_int; +} +extern "C" { + pub fn gets_s(arg1: *mut ::std::os::raw::c_char, arg2: rsize_t) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn perror(arg1: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn printf(arg1: *const ::std::os::raw::c_char, ...) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn putc(arg1: ::std::os::raw::c_int, arg2: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn putchar(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn puts(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn remove(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rename(arg1: *const ::std::os::raw::c_char, arg2: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rewind(arg1: *mut FILE); +} +extern "C" { + pub fn scanf(arg1: *const ::std::os::raw::c_char, ...) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setbuf(arg1: *mut FILE, arg2: *mut ::std::os::raw::c_char); +} +extern "C" { + pub fn setvbuf( + arg1: *mut FILE, + arg2: *mut ::std::os::raw::c_char, + arg3: ::std::os::raw::c_int, + arg4: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn sprintf( + arg1: *mut ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + ... + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn sscanf( + arg1: *const ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + ... + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn tmpfile() -> *mut FILE; +} +extern "C" { + pub fn tmpnam(arg1: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ungetc(arg1: ::std::os::raw::c_int, arg2: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn vfprintf( + arg1: *mut FILE, + arg2: *const ::std::os::raw::c_char, + arg3: *mut __va_list_tag, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn vprintf(arg1: *const ::std::os::raw::c_char, arg2: *mut __va_list_tag) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn vsprintf( + arg1: *mut ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + arg3: *mut __va_list_tag, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn snprintf( + arg1: *mut ::std::os::raw::c_char, + arg2: ::std::os::raw::c_ulong, + arg3: *const ::std::os::raw::c_char, + ... + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn vsnprintf( + arg1: *mut ::std::os::raw::c_char, + arg2: ::std::os::raw::c_ulong, + arg3: *const ::std::os::raw::c_char, + arg4: *mut __va_list_tag, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn vfscanf( + arg1: *mut FILE, + arg2: *const ::std::os::raw::c_char, + arg3: *mut __va_list_tag, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn vscanf(arg1: *const ::std::os::raw::c_char, arg2: *mut __va_list_tag) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn vsscanf( + arg1: *const ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + arg3: *mut __va_list_tag, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ctermid(arg1: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn fdopen(arg1: ::std::os::raw::c_int, arg2: *const ::std::os::raw::c_char) -> *mut FILE; +} +extern "C" { + pub fn fileno(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pclose(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn popen(arg1: *const ::std::os::raw::c_char, arg2: *const ::std::os::raw::c_char) -> *mut FILE; +} +extern "C" { + pub fn ftrylockfile(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn flockfile(arg1: *mut FILE); +} +extern "C" { + pub fn funlockfile(arg1: *mut FILE); +} +extern "C" { + pub fn getc_unlocked(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getchar_unlocked() -> ::std::os::raw::c_int; +} +extern "C" { + pub fn putc_unlocked(arg1: ::std::os::raw::c_int, arg2: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn putchar_unlocked(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clearerr_unlocked(arg1: *mut FILE); +} +extern "C" { + pub fn feof_unlocked(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ferror_unlocked(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fflush_unlocked(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fileno_unlocked(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fputc_unlocked(arg1: ::std::os::raw::c_int, arg2: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fputs_unlocked(arg1: *const ::std::os::raw::c_char, arg2: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fread_unlocked(arg1: *mut ::std::os::raw::c_void, arg2: usize, arg3: usize, arg4: *mut FILE) -> usize; +} +extern "C" { + pub fn fwrite_unlocked(arg1: *const ::std::os::raw::c_void, arg2: usize, arg3: usize, arg4: *mut FILE) -> usize; +} +extern "C" { + pub fn fseeko(arg1: *mut FILE, arg2: __off_t, arg3: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ftello(arg1: *mut FILE) -> __off_t; +} +extern "C" { + pub fn getw(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn putw(arg1: ::std::os::raw::c_int, arg2: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn tempnam( + arg1: *const ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn fmemopen(arg1: *mut ::std::os::raw::c_void, arg2: usize, arg3: *const ::std::os::raw::c_char) -> *mut FILE; +} +extern "C" { + pub fn getdelim( + arg1: *mut *mut ::std::os::raw::c_char, + arg2: *mut usize, + arg3: ::std::os::raw::c_int, + arg4: *mut FILE, + ) -> isize; +} +extern "C" { + pub fn open_memstream(arg1: *mut *mut ::std::os::raw::c_char, arg2: *mut usize) -> *mut FILE; +} +extern "C" { + pub fn renameat( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_char, + arg3: ::std::os::raw::c_int, + arg4: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn vdprintf( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_char, + arg3: *mut __va_list_tag, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getline(arg1: *mut *mut ::std::os::raw::c_char, arg2: *mut usize, arg3: *mut FILE) -> isize; +} +extern "C" { + pub fn dprintf(arg1: ::std::os::raw::c_int, arg2: *const ::std::os::raw::c_char, ...) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn asprintf( + arg1: *mut *mut ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + ... + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ctermid_r(arg1: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn fcloseall(); +} +extern "C" { + pub fn fdclose(arg1: *mut FILE, arg2: *mut ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fgetln(arg1: *mut FILE, arg2: *mut usize) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn fmtcheck( + arg1: *const ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + ) -> *const ::std::os::raw::c_char; +} +extern "C" { + pub fn fpurge(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setbuffer(arg1: *mut FILE, arg2: *mut ::std::os::raw::c_char, arg3: ::std::os::raw::c_int); +} +extern "C" { + pub fn setlinebuf(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn vasprintf( + arg1: *mut *mut ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + arg3: *mut __va_list_tag, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub static sys_nerr: ::std::os::raw::c_int; +} +extern "C" { + pub static sys_errlist: [*const ::std::os::raw::c_char; 0usize]; +} +extern "C" { + pub fn funopen( + arg1: *const ::std::os::raw::c_void, + arg2: ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_char, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int, + >, + arg3: ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_char, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int, + >, + arg4: ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: fpos_t, + arg3: ::std::os::raw::c_int, + ) -> fpos_t, + >, + arg5: ::std::option::Option ::std::os::raw::c_int>, + ) -> *mut FILE; +} +pub type cookie_read_function_t = ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_char, + arg3: usize, + ) -> __ssize_t, +>; +pub type cookie_write_function_t = ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_char, + arg3: usize, + ) -> __ssize_t, +>; +pub type cookie_seek_function_t = ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut off64_t, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int, +>; +pub type cookie_close_function_t = + ::std::option::Option ::std::os::raw::c_int>; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct cookie_io_functions_t { + pub read: cookie_read_function_t, + pub write: cookie_write_function_t, + pub seek: cookie_seek_function_t, + pub close: cookie_close_function_t, +} +#[test] +fn bindgen_test_layout_cookie_io_functions_t() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(cookie_io_functions_t)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(cookie_io_functions_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).read) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(cookie_io_functions_t), + "::", + stringify!(read) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).write) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(cookie_io_functions_t), + "::", + stringify!(write) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seek) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(cookie_io_functions_t), + "::", + stringify!(seek) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).close) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(cookie_io_functions_t), + "::", + stringify!(close) + ) + ); +} +extern "C" { + pub fn fopencookie( + arg1: *mut ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_char, + arg3: cookie_io_functions_t, + ) -> *mut FILE; +} +extern "C" { + pub fn __srget(arg1: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn __swbuf(arg1: ::std::os::raw::c_int, arg2: *mut FILE) -> ::std::os::raw::c_int; +} +extern "C" { + pub static mut __isthreaded: ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct FreeBSD_nvlist { + _unused: [u8; 0], +} +pub type FreeBSD_nvlist_t = FreeBSD_nvlist; +extern "C" { + pub fn FreeBSD_nvlist_create(flags: ::std::os::raw::c_int) -> *mut FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_destroy(nvl: *mut FreeBSD_nvlist_t); +} +extern "C" { + pub fn FreeBSD_nvlist_error(nvl: *const FreeBSD_nvlist_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn FreeBSD_nvlist_empty(nvl: *const FreeBSD_nvlist_t) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_flags(nvl: *const FreeBSD_nvlist_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn FreeBSD_nvlist_set_error(nvl: *mut FreeBSD_nvlist_t, error: ::std::os::raw::c_int); +} +extern "C" { + pub fn FreeBSD_nvlist_clone(nvl: *const FreeBSD_nvlist_t) -> *mut FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_dump(nvl: *const FreeBSD_nvlist_t, fd: ::std::os::raw::c_int); +} +extern "C" { + pub fn FreeBSD_nvlist_fdump(nvl: *const FreeBSD_nvlist_t, fp: *mut FILE); +} +extern "C" { + pub fn FreeBSD_nvlist_size(nvl: *const FreeBSD_nvlist_t) -> usize; +} +extern "C" { + pub fn FreeBSD_nvlist_pack(nvl: *const FreeBSD_nvlist_t, sizep: *mut usize) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn FreeBSD_nvlist_unpack( + buf: *const ::std::os::raw::c_void, + size: usize, + flags: ::std::os::raw::c_int, + ) -> *mut FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_send(sock: ::std::os::raw::c_int, nvl: *const FreeBSD_nvlist_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn FreeBSD_nvlist_recv(sock: ::std::os::raw::c_int, flags: ::std::os::raw::c_int) -> *mut FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_xfer( + sock: ::std::os::raw::c_int, + nvl: *mut FreeBSD_nvlist_t, + flags: ::std::os::raw::c_int, + ) -> *mut FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_next( + nvl: *const FreeBSD_nvlist_t, + typep: *mut ::std::os::raw::c_int, + cookiep: *mut *mut ::std::os::raw::c_void, + ) -> *const ::std::os::raw::c_char; +} +extern "C" { + pub fn FreeBSD_nvlist_get_parent( + nvl: *const FreeBSD_nvlist_t, + cookiep: *mut *mut ::std::os::raw::c_void, + ) -> *const FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_get_array_next(nvl: *const FreeBSD_nvlist_t) -> *const FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_in_array(nvl: *const FreeBSD_nvlist_t) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_get_pararr( + nvl: *const FreeBSD_nvlist_t, + cookiep: *mut *mut ::std::os::raw::c_void, + ) -> *const FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_exists(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_type( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + type_: ::std::os::raw::c_int, + ) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_null(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_bool(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_number(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_string(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_nvlist(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_binary(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_bool_array(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_number_array( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_string_array( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_nvlist_array( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_descriptor(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_exists_descriptor_array( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_add_null(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_add_bool(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char, value: bool); +} +extern "C" { + pub fn FreeBSD_nvlist_add_number(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char, value: u64); +} +extern "C" { + pub fn FreeBSD_nvlist_add_string( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const ::std::os::raw::c_char, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_stringf( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + valuefmt: *const ::std::os::raw::c_char, + ... + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_stringv( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + valuefmt: *const ::std::os::raw::c_char, + valueap: *mut __va_list_tag, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_nvlist( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const FreeBSD_nvlist_t, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_binary( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const ::std::os::raw::c_void, + size: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_bool_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const bool, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_number_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const u64, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_string_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const *const ::std::os::raw::c_char, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_nvlist_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const *const FreeBSD_nvlist_t, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_descriptor( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: ::std::os::raw::c_int, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_add_descriptor_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const ::std::os::raw::c_int, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_append_bool_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: bool, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_append_number_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: u64, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_append_string_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const ::std::os::raw::c_char, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_append_nvlist_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *const FreeBSD_nvlist_t, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_append_descriptor_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: ::std::os::raw::c_int, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_move_string( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *mut ::std::os::raw::c_char, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_move_nvlist( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *mut FreeBSD_nvlist_t, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_move_binary( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *mut ::std::os::raw::c_void, + size: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_move_bool_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *mut bool, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_move_string_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *mut *mut ::std::os::raw::c_char, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_move_nvlist_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *mut *mut FreeBSD_nvlist_t, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_move_number_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *mut u64, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_move_descriptor( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: ::std::os::raw::c_int, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_move_descriptor_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + value: *mut ::std::os::raw::c_int, + nitems: usize, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_get_bool(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_get_number(nvl: *const FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> u64; +} +extern "C" { + pub fn FreeBSD_nvlist_get_string( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> *const ::std::os::raw::c_char; +} +extern "C" { + pub fn FreeBSD_nvlist_get_nvlist( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> *const FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_get_binary( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + sizep: *mut usize, + ) -> *const ::std::os::raw::c_void; +} +extern "C" { + pub fn FreeBSD_nvlist_get_bool_array( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *const bool; +} +extern "C" { + pub fn FreeBSD_nvlist_get_number_array( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *const u64; +} +extern "C" { + pub fn FreeBSD_nvlist_get_string_array( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *const *const ::std::os::raw::c_char; +} +extern "C" { + pub fn FreeBSD_nvlist_get_nvlist_array( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *const *const FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_get_descriptor( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn FreeBSD_nvlist_get_descriptor_array( + nvl: *const FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *const ::std::os::raw::c_int; +} +extern "C" { + pub fn FreeBSD_nvlist_take_bool(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> bool; +} +extern "C" { + pub fn FreeBSD_nvlist_take_number(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char) -> u64; +} +extern "C" { + pub fn FreeBSD_nvlist_take_string( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn FreeBSD_nvlist_take_nvlist( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> *mut FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_take_binary( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + sizep: *mut usize, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn FreeBSD_nvlist_take_bool_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *mut bool; +} +extern "C" { + pub fn FreeBSD_nvlist_take_number_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *mut u64; +} +extern "C" { + pub fn FreeBSD_nvlist_take_string_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *mut *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn FreeBSD_nvlist_take_nvlist_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *mut *mut FreeBSD_nvlist_t; +} +extern "C" { + pub fn FreeBSD_nvlist_take_descriptor( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn FreeBSD_nvlist_take_descriptor_array( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + nitemsp: *mut usize, + ) -> *mut ::std::os::raw::c_int; +} +extern "C" { + pub fn FreeBSD_nvlist_free(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_type( + nvl: *mut FreeBSD_nvlist_t, + name: *const ::std::os::raw::c_char, + type_: ::std::os::raw::c_int, + ); +} +extern "C" { + pub fn FreeBSD_nvlist_free_null(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_bool(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_number(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_string(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_nvlist(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_binary(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_bool_array(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_number_array(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_string_array(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_nvlist_array(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_binary_array(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_descriptor(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +extern "C" { + pub fn FreeBSD_nvlist_free_descriptor_array(nvl: *mut FreeBSD_nvlist_t, name: *const ::std::os::raw::c_char); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __hack { + _unused: [u8; 0], +} +extern "C" { + pub fn sysctl( + arg1: *const ::std::os::raw::c_int, + arg2: ::std::os::raw::c_uint, + arg3: *mut ::std::os::raw::c_void, + arg4: *mut usize, + arg5: *const ::std::os::raw::c_void, + arg6: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn sysctlbyname( + arg1: *const ::std::os::raw::c_char, + arg2: *mut ::std::os::raw::c_void, + arg3: *mut usize, + arg4: *const ::std::os::raw::c_void, + arg5: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn sysctlnametomib( + arg1: *const ::std::os::raw::c_char, + arg2: *mut ::std::os::raw::c_int, + arg3: *mut usize, + ) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct lock_list_entry { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct thread { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct lock_class { + pub lc_name: *const ::std::os::raw::c_char, + pub lc_flags: u_int, + pub lc_assert: ::std::option::Option, + pub lc_ddb_show: ::std::option::Option, + pub lc_lock: ::std::option::Option, + pub lc_owner: ::std::option::Option< + unsafe extern "C" fn(lock: *const lock_object, owner: *mut *mut thread) -> ::std::os::raw::c_int, + >, + pub lc_unlock: ::std::option::Option usize>, +} +#[test] +fn bindgen_test_layout_lock_class() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(lock_class)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(lock_class)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lc_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(lock_class), "::", stringify!(lc_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lc_flags) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(lock_class), "::", stringify!(lc_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lc_assert) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(lock_class), "::", stringify!(lc_assert)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lc_ddb_show) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(lock_class), + "::", + stringify!(lc_ddb_show) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lc_lock) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(lock_class), "::", stringify!(lc_lock)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lc_owner) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(lock_class), "::", stringify!(lc_owner)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lc_unlock) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(lock_class), "::", stringify!(lc_unlock)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sx { + pub lock_object: lock_object, + pub sx_lock: usize, +} +#[test] +fn bindgen_test_layout_sx() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(sx)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sx)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lock_object) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sx), "::", stringify!(lock_object)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sx_lock) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(sx), "::", stringify!(sx_lock)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rmpriolist { + pub lh_first: *mut rm_priotracker, +} +#[test] +fn bindgen_test_layout_rmpriolist() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(rmpriolist)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rmpriolist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lh_first) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rmpriolist), "::", stringify!(lh_first)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rm_queue { + pub rmq_next: *mut rm_queue, + pub rmq_prev: *mut rm_queue, +} +#[test] +fn bindgen_test_layout_rm_queue() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(rm_queue)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rm_queue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmq_next) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rm_queue), "::", stringify!(rmq_next)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmq_prev) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(rm_queue), "::", stringify!(rmq_prev)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct rmlock { + pub lock_object: lock_object, + pub rm_writecpus: cpuset_t, + pub rm_activeReaders: rmlock__bindgen_ty_1, + pub _rm_lock: rmlock__bindgen_ty_2, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rmlock__bindgen_ty_1 { + pub lh_first: *mut rm_priotracker, +} +#[test] +fn bindgen_test_layout_rmlock__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(rmlock__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rmlock__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rmlock__bindgen_ty_1), + "::", + stringify!(lh_first) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union rmlock__bindgen_ty_2 { + pub _rm_wlock_object: lock_object, + pub _rm_lock_mtx: mtx, + pub _rm_lock_sx: sx, +} +#[test] +fn bindgen_test_layout_rmlock__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(rmlock__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rmlock__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._rm_wlock_object) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rmlock__bindgen_ty_2), + "::", + stringify!(_rm_wlock_object) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._rm_lock_mtx) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rmlock__bindgen_ty_2), + "::", + stringify!(_rm_lock_mtx) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._rm_lock_sx) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rmlock__bindgen_ty_2), + "::", + stringify!(_rm_lock_sx) + ) + ); +} +#[test] +fn bindgen_test_layout_rmlock() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 192usize, + concat!("Size of: ", stringify!(rmlock)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rmlock)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lock_object) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rmlock), "::", stringify!(lock_object)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_writecpus) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(rmlock), "::", stringify!(rm_writecpus)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_activeReaders) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(rmlock), + "::", + stringify!(rm_activeReaders) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._rm_lock) as usize - ptr as usize }, + 160usize, + concat!("Offset of field: ", stringify!(rmlock), "::", stringify!(_rm_lock)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rm_priotracker { + pub rmp_cpuQueue: rm_queue, + pub rmp_rmlock: *mut rmlock, + pub rmp_thread: *mut thread, + pub rmp_flags: ::std::os::raw::c_int, + pub rmp_qentry: rm_priotracker__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rm_priotracker__bindgen_ty_1 { + pub le_next: *mut rm_priotracker, + pub le_prev: *mut *mut rm_priotracker, +} +#[test] +fn bindgen_test_layout_rm_priotracker__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(rm_priotracker__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rm_priotracker__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).le_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rm_priotracker__bindgen_ty_1), + "::", + stringify!(le_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).le_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(rm_priotracker__bindgen_ty_1), + "::", + stringify!(le_prev) + ) + ); +} +#[test] +fn bindgen_test_layout_rm_priotracker() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(rm_priotracker)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rm_priotracker)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmp_cpuQueue) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rm_priotracker), + "::", + stringify!(rmp_cpuQueue) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmp_rmlock) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(rm_priotracker), + "::", + stringify!(rmp_rmlock) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmp_thread) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(rm_priotracker), + "::", + stringify!(rmp_thread) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmp_flags) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(rm_priotracker), + "::", + stringify!(rmp_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmp_qentry) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(rm_priotracker), + "::", + stringify!(rmp_qentry) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rmslock_pcpu { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rmslock { + pub mtx: mtx, + pub owner: *mut thread, + pub pcpu: *mut rmslock_pcpu, + pub writers: ::std::os::raw::c_int, + pub readers: ::std::os::raw::c_int, + pub debug_readers: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_rmslock() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(rmslock)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rmslock)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mtx) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rmslock), "::", stringify!(mtx)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).owner) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(rmslock), "::", stringify!(owner)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pcpu) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(rmslock), "::", stringify!(pcpu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).writers) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(rmslock), "::", stringify!(writers)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).readers) as usize - ptr as usize }, + 52usize, + concat!("Offset of field: ", stringify!(rmslock), "::", stringify!(readers)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).debug_readers) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(rmslock), + "::", + stringify!(debug_readers) + ) + ); +} +pub type seqc_t = u32; +pub type smr_seq_t = u32; +pub type smr_delta_t = i32; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct smr { + _unused: [u8; 0], +} +pub type smr_t = *mut smr; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct uma_zone { + _unused: [u8; 0], +} +pub type uma_zone_t = *mut uma_zone; +pub type uma_ctor = ::std::option::Option< + unsafe extern "C" fn( + mem: *mut ::std::os::raw::c_void, + size: ::std::os::raw::c_int, + arg: *mut ::std::os::raw::c_void, + flags: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int, +>; +pub type uma_dtor = ::std::option::Option< + unsafe extern "C" fn( + mem: *mut ::std::os::raw::c_void, + size: ::std::os::raw::c_int, + arg: *mut ::std::os::raw::c_void, + ), +>; +pub type uma_init = ::std::option::Option< + unsafe extern "C" fn( + mem: *mut ::std::os::raw::c_void, + size: ::std::os::raw::c_int, + flags: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int, +>; +pub type uma_fini = + ::std::option::Option; +pub type uma_import = ::std::option::Option< + unsafe extern "C" fn( + arg: *mut ::std::os::raw::c_void, + store: *mut *mut ::std::os::raw::c_void, + count: ::std::os::raw::c_int, + domain: ::std::os::raw::c_int, + flags: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int, +>; +pub type uma_release = ::std::option::Option< + unsafe extern "C" fn( + arg: *mut ::std::os::raw::c_void, + store: *mut *mut ::std::os::raw::c_void, + count: ::std::os::raw::c_int, + ), +>; +extern "C" { + pub fn uma_zcreate( + name: *const ::std::os::raw::c_char, + size: usize, + ctor: uma_ctor, + dtor: uma_dtor, + uminit: uma_init, + fini: uma_fini, + align: ::std::os::raw::c_int, + flags: u32, + ) -> uma_zone_t; +} +extern "C" { + pub fn uma_zsecond_create( + name: *const ::std::os::raw::c_char, + ctor: uma_ctor, + dtor: uma_dtor, + zinit: uma_init, + zfini: uma_fini, + primary: uma_zone_t, + ) -> uma_zone_t; +} +extern "C" { + pub fn uma_zcache_create( + name: *const ::std::os::raw::c_char, + size: ::std::os::raw::c_int, + ctor: uma_ctor, + dtor: uma_dtor, + zinit: uma_init, + zfini: uma_fini, + zimport: uma_import, + zrelease: uma_release, + arg: *mut ::std::os::raw::c_void, + flags: ::std::os::raw::c_int, + ) -> uma_zone_t; +} +extern "C" { + pub fn uma_zdestroy(zone: uma_zone_t); +} +extern "C" { + pub fn uma_zalloc_arg( + zone: uma_zone_t, + arg: *mut ::std::os::raw::c_void, + flags: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn uma_zalloc_pcpu_arg( + zone: uma_zone_t, + arg: *mut ::std::os::raw::c_void, + flags: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn uma_zalloc_smr(zone: uma_zone_t, flags: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn uma_zalloc_domain( + zone: uma_zone_t, + arg: *mut ::std::os::raw::c_void, + domain: ::std::os::raw::c_int, + flags: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn uma_zfree_arg(zone: uma_zone_t, item: *mut ::std::os::raw::c_void, arg: *mut ::std::os::raw::c_void); +} +extern "C" { + pub fn uma_zfree_pcpu_arg(zone: uma_zone_t, item: *mut ::std::os::raw::c_void, arg: *mut ::std::os::raw::c_void); +} +extern "C" { + pub fn uma_zfree_smr(zone: uma_zone_t, item: *mut ::std::os::raw::c_void); +} +extern "C" { + pub fn uma_zwait(zone: uma_zone_t); +} +pub type uma_alloc = ::std::option::Option< + unsafe extern "C" fn( + zone: uma_zone_t, + size: vm_size_t, + domain: ::std::os::raw::c_int, + pflag: *mut u8, + wait: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_void, +>; +pub type uma_free = + ::std::option::Option; +extern "C" { + pub fn uma_reclaim(req: ::std::os::raw::c_int); +} +extern "C" { + pub fn uma_reclaim_domain(req: ::std::os::raw::c_int, domain: ::std::os::raw::c_int); +} +extern "C" { + pub fn uma_zone_reclaim(arg1: uma_zone_t, req: ::std::os::raw::c_int); +} +extern "C" { + pub fn uma_zone_reclaim_domain(arg1: uma_zone_t, req: ::std::os::raw::c_int, domain: ::std::os::raw::c_int); +} +extern "C" { + pub fn uma_set_align(align: ::std::os::raw::c_int); +} +extern "C" { + pub fn uma_zone_reserve(zone: uma_zone_t, nitems: ::std::os::raw::c_int); +} +extern "C" { + pub fn uma_zone_reserve_kva(zone: uma_zone_t, nitems: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn uma_zone_set_max(zone: uma_zone_t, nitems: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn uma_zone_set_maxcache(zone: uma_zone_t, nitems: ::std::os::raw::c_int); +} +extern "C" { + pub fn uma_zone_get_max(zone: uma_zone_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn uma_zone_set_warning(zone: uma_zone_t, warning: *const ::std::os::raw::c_char); +} +pub type uma_maxaction_t = ::std::option::Option; +extern "C" { + pub fn uma_zone_set_maxaction(zone: uma_zone_t, arg1: uma_maxaction_t); +} +extern "C" { + pub fn uma_zone_get_cur(zone: uma_zone_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn uma_zone_set_init(zone: uma_zone_t, uminit: uma_init); +} +extern "C" { + pub fn uma_zone_set_fini(zone: uma_zone_t, fini: uma_fini); +} +extern "C" { + pub fn uma_zone_set_zinit(zone: uma_zone_t, zinit: uma_init); +} +extern "C" { + pub fn uma_zone_set_zfini(zone: uma_zone_t, zfini: uma_fini); +} +extern "C" { + pub fn uma_zone_set_allocf(zone: uma_zone_t, allocf: uma_alloc); +} +extern "C" { + pub fn uma_zone_set_freef(zone: uma_zone_t, freef: uma_free); +} +extern "C" { + pub fn uma_zone_set_smr(zone: uma_zone_t, smr: smr_t); +} +extern "C" { + pub fn uma_zone_get_smr(zone: uma_zone_t) -> smr_t; +} +extern "C" { + pub fn uma_prealloc(zone: uma_zone_t, itemcnt: ::std::os::raw::c_int); +} +extern "C" { + pub fn uma_zone_exhausted(zone: uma_zone_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn uma_zone_memory(zone: uma_zone_t) -> usize; +} +extern "C" { + pub static mut pcpu_zone_4: uma_zone_t; +} +extern "C" { + pub static mut pcpu_zone_8: uma_zone_t; +} +extern "C" { + pub static mut pcpu_zone_16: uma_zone_t; +} +extern "C" { + pub static mut pcpu_zone_32: uma_zone_t; +} +extern "C" { + pub static mut pcpu_zone_64: uma_zone_t; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct uma_stream_header { + pub ush_version: u32, + pub ush_maxcpus: u32, + pub ush_count: u32, + pub _ush_pad: u32, +} +#[test] +fn bindgen_test_layout_uma_stream_header() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(uma_stream_header)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(uma_stream_header)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ush_version) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(uma_stream_header), + "::", + stringify!(ush_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ush_maxcpus) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(uma_stream_header), + "::", + stringify!(ush_maxcpus) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ush_count) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(uma_stream_header), + "::", + stringify!(ush_count) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ush_pad) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(uma_stream_header), + "::", + stringify!(_ush_pad) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct uma_type_header { + pub uth_name: [::std::os::raw::c_char; 32usize], + pub uth_align: u32, + pub uth_size: u32, + pub uth_rsize: u32, + pub uth_maxpages: u32, + pub uth_limit: u32, + pub uth_pages: u32, + pub uth_keg_free: u32, + pub uth_zone_free: u32, + pub uth_bucketsize: u32, + pub uth_zone_flags: u32, + pub uth_allocs: u64, + pub uth_frees: u64, + pub uth_fails: u64, + pub uth_sleeps: u64, + pub uth_xdomain: u64, + pub _uth_reserved1: [u64; 1usize], +} +#[test] +fn bindgen_test_layout_uma_type_header() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 120usize, + concat!("Size of: ", stringify!(uma_type_header)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(uma_type_header)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_align) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_align) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_size) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_rsize) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_rsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_maxpages) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_maxpages) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_limit) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_limit) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_pages) as usize - ptr as usize }, + 52usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_pages) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_keg_free) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_keg_free) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_zone_free) as usize - ptr as usize }, + 60usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_zone_free) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_bucketsize) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_bucketsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_zone_flags) as usize - ptr as usize }, + 68usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_zone_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_allocs) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_allocs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_frees) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_frees) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_fails) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_fails) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_sleeps) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_sleeps) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uth_xdomain) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(uth_xdomain) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._uth_reserved1) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(uma_type_header), + "::", + stringify!(_uth_reserved1) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct uma_percpu_stat { + pub ups_allocs: u64, + pub ups_frees: u64, + pub ups_cache_free: u64, + pub _ups_reserved: [u64; 5usize], +} +#[test] +fn bindgen_test_layout_uma_percpu_stat() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(uma_percpu_stat)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(uma_percpu_stat)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ups_allocs) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(uma_percpu_stat), + "::", + stringify!(ups_allocs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ups_frees) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(uma_percpu_stat), + "::", + stringify!(ups_frees) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ups_cache_free) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(uma_percpu_stat), + "::", + stringify!(ups_cache_free) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ups_reserved) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(uma_percpu_stat), + "::", + stringify!(_ups_reserved) + ) + ); +} +extern "C" { + pub fn uma_reclaim_wakeup(); +} +extern "C" { + pub fn uma_reclaim_worker(arg1: *mut ::std::os::raw::c_void); +} +extern "C" { + pub fn uma_limit() -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn uma_size() -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn uma_avail() -> ::std::os::raw::c_long; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timezone { + pub tz_minuteswest: ::std::os::raw::c_int, + pub tz_dsttime: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_timezone() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(timezone)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(timezone)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tz_minuteswest) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timezone), + "::", + stringify!(tz_minuteswest) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tz_dsttime) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(timezone), "::", stringify!(tz_dsttime)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct bintime { + pub sec: time_t, + pub frac: u64, +} +#[test] +fn bindgen_test_layout_bintime() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(bintime)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(bintime)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(bintime), "::", stringify!(sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).frac) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(bintime), "::", stringify!(frac)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct itimerval { + pub it_interval: timeval, + pub it_value: timeval, +} +#[test] +fn bindgen_test_layout_itimerval() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(itimerval)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(itimerval)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_interval) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(itimerval), + "::", + stringify!(it_interval) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_value) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(itimerval), "::", stringify!(it_value)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct clockinfo { + pub hz: ::std::os::raw::c_int, + pub tick: ::std::os::raw::c_int, + pub spare: ::std::os::raw::c_int, + pub stathz: ::std::os::raw::c_int, + pub profhz: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_clockinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(clockinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(clockinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hz) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(hz)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tick) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(tick)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).spare) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(spare)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).stathz) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(stathz)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).profhz) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(profhz)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct tm { + pub tm_sec: ::std::os::raw::c_int, + pub tm_min: ::std::os::raw::c_int, + pub tm_hour: ::std::os::raw::c_int, + pub tm_mday: ::std::os::raw::c_int, + pub tm_mon: ::std::os::raw::c_int, + pub tm_year: ::std::os::raw::c_int, + pub tm_wday: ::std::os::raw::c_int, + pub tm_yday: ::std::os::raw::c_int, + pub tm_isdst: ::std::os::raw::c_int, + pub tm_gmtoff: ::std::os::raw::c_long, + pub tm_zone: *mut ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_tm() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(tm)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(tm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_min) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_min)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_hour) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_hour)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_mday) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_mday)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_mon) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_mon)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_year) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_year)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_wday) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_wday)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_yday) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_yday)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_isdst) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_isdst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_gmtoff) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_gmtoff)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_zone) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_zone)) + ); +} +extern "C" { + pub static mut tzname: [*mut ::std::os::raw::c_char; 0usize]; +} +extern "C" { + pub fn asctime(arg1: *const tm) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn clock() -> clock_t; +} +extern "C" { + pub fn ctime(arg1: *const time_t) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn difftime(arg1: time_t, arg2: time_t) -> f64; +} +extern "C" { + pub fn gmtime(arg1: *const time_t) -> *mut tm; +} +extern "C" { + pub fn localtime(arg1: *const time_t) -> *mut tm; +} +extern "C" { + pub fn mktime(arg1: *mut tm) -> time_t; +} +extern "C" { + pub fn strftime( + arg1: *mut ::std::os::raw::c_char, + arg2: usize, + arg3: *const ::std::os::raw::c_char, + arg4: *const tm, + ) -> usize; +} +extern "C" { + pub fn time(arg1: *mut time_t) -> time_t; +} +extern "C" { + pub fn timer_create(arg1: clockid_t, arg2: *mut sigevent, arg3: *mut timer_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn timer_delete(arg1: timer_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn timer_gettime(arg1: timer_t, arg2: *mut itimerspec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn timer_getoverrun(arg1: timer_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn timer_settime( + arg1: timer_t, + arg2: ::std::os::raw::c_int, + arg3: *const itimerspec, + arg4: *mut itimerspec, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn tzset(); +} +extern "C" { + pub fn clock_getres(arg1: clockid_t, arg2: *mut timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_gettime(arg1: clockid_t, arg2: *mut timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_settime(arg1: clockid_t, arg2: *const timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn nanosleep(arg1: *const timespec, arg2: *mut timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_getcpuclockid(arg1: pid_t, arg2: *mut clockid_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_nanosleep( + arg1: clockid_t, + arg2: ::std::os::raw::c_int, + arg3: *const timespec, + arg4: *mut timespec, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn asctime_r(arg1: *const tm, arg2: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ctime_r(arg1: *const time_t, arg2: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn gmtime_r(arg1: *const time_t, arg2: *mut tm) -> *mut tm; +} +extern "C" { + pub fn localtime_r(arg1: *const time_t, arg2: *mut tm) -> *mut tm; +} +extern "C" { + pub fn strptime( + arg1: *const ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + arg3: *mut tm, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn timezone(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn timelocal(arg1: *mut tm) -> time_t; +} +extern "C" { + pub fn timegm(arg1: *mut tm) -> time_t; +} +extern "C" { + pub fn timer_oshandle_np(timerid: timer_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn time2posix(t: time_t) -> time_t; +} +extern "C" { + pub fn posix2time(t: time_t) -> time_t; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _xlocale { + _unused: [u8; 0], +} +pub type locale_t = *mut _xlocale; +extern "C" { + pub fn strftime_l( + arg1: *mut ::std::os::raw::c_char, + arg2: usize, + arg3: *const ::std::os::raw::c_char, + arg4: *const tm, + arg5: locale_t, + ) -> usize; +} +extern "C" { + pub fn timespec_get(ts: *mut timespec, base: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn timespec_getres(arg1: *mut timespec, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setitimer( + arg1: ::std::os::raw::c_int, + arg2: *const itimerval, + arg3: *mut itimerval, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn utimes(arg1: *const ::std::os::raw::c_char, arg2: *const timeval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn adjtime(arg1: *const timeval, arg2: *mut timeval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_getcpuclockid2(arg1: id_t, arg2: ::std::os::raw::c_int, arg3: *mut clockid_t) + -> ::std::os::raw::c_int; +} +extern "C" { + pub fn futimes(arg1: ::std::os::raw::c_int, arg2: *const timeval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn futimesat( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_char, + arg3: *const timeval, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn lutimes(arg1: *const ::std::os::raw::c_char, arg2: *const timeval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn settimeofday(arg1: *const timeval, arg2: *const timezone) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getitimer(arg1: ::std::os::raw::c_int, arg2: *mut itimerval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn gettimeofday(arg1: *mut timeval, arg2: *mut timezone) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct iovec { + pub iov_base: *mut ::std::os::raw::c_void, + pub iov_len: usize, +} +#[test] +fn bindgen_test_layout_iovec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(iovec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(iovec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iov_base) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(iovec), "::", stringify!(iov_base)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iov_len) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(iovec), "::", stringify!(iov_len)) + ); +} +pub type sa_family_t = __sa_family_t; +pub type socklen_t = __socklen_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct linger { + pub l_onoff: ::std::os::raw::c_int, + pub l_linger: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_linger() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(linger)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(linger)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).l_onoff) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(linger), "::", stringify!(l_onoff)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).l_linger) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(linger), "::", stringify!(l_linger)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct accept_filter_arg { + pub af_name: [::std::os::raw::c_char; 16usize], + pub af_arg: [::std::os::raw::c_char; 240usize], +} +#[test] +fn bindgen_test_layout_accept_filter_arg() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 256usize, + concat!("Size of: ", stringify!(accept_filter_arg)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(accept_filter_arg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(accept_filter_arg), + "::", + stringify!(af_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af_arg) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(accept_filter_arg), + "::", + stringify!(af_arg) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr { + pub sa_len: ::std::os::raw::c_uchar, + pub sa_family: sa_family_t, + pub sa_data: [::std::os::raw::c_char; 14usize], +} +#[test] +fn bindgen_test_layout_sockaddr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sockaddr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(sockaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr), "::", stringify!(sa_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_family) as usize - ptr as usize }, + 1usize, + concat!("Offset of field: ", stringify!(sockaddr), "::", stringify!(sa_family)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_data) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(sockaddr), "::", stringify!(sa_data)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockproto { + pub sp_family: ::std::os::raw::c_ushort, + pub sp_protocol: ::std::os::raw::c_ushort, +} +#[test] +fn bindgen_test_layout_sockproto() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(sockproto)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(sockproto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sp_family) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockproto), "::", stringify!(sp_family)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sp_protocol) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockproto), + "::", + stringify!(sp_protocol) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_storage { + pub ss_len: ::std::os::raw::c_uchar, + pub ss_family: sa_family_t, + pub __ss_pad1: [::std::os::raw::c_char; 6usize], + pub __ss_align: __int64_t, + pub __ss_pad2: [::std::os::raw::c_char; 112usize], +} +#[test] +fn bindgen_test_layout_sockaddr_storage() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(sockaddr_storage)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sockaddr_storage)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(ss_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(ss_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss_pad1) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(__ss_pad1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss_align) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(__ss_align) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss_pad2) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(__ss_pad2) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct msghdr { + pub msg_name: *mut ::std::os::raw::c_void, + pub msg_namelen: socklen_t, + pub msg_iov: *mut iovec, + pub msg_iovlen: ::std::os::raw::c_int, + pub msg_control: *mut ::std::os::raw::c_void, + pub msg_controllen: socklen_t, + pub msg_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_namelen) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_namelen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iov) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_iov)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iovlen) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_iovlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_control) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_control)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_controllen) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(msghdr), + "::", + stringify!(msg_controllen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_flags) as usize - ptr as usize }, + 44usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct cmsghdr { + pub cmsg_len: socklen_t, + pub cmsg_level: ::std::os::raw::c_int, + pub cmsg_type: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_cmsghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(cmsghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(cmsghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmsg_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(cmsghdr), "::", stringify!(cmsg_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmsg_level) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(cmsghdr), "::", stringify!(cmsg_level)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmsg_type) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(cmsghdr), "::", stringify!(cmsg_type)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct cmsgcred { + pub cmcred_pid: pid_t, + pub cmcred_uid: uid_t, + pub cmcred_euid: uid_t, + pub cmcred_gid: gid_t, + pub cmcred_ngroups: ::std::os::raw::c_short, + pub cmcred_groups: [gid_t; 16usize], +} +#[test] +fn bindgen_test_layout_cmsgcred() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 84usize, + concat!("Size of: ", stringify!(cmsgcred)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(cmsgcred)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmcred_pid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(cmsgcred), "::", stringify!(cmcred_pid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmcred_uid) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(cmsgcred), "::", stringify!(cmcred_uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmcred_euid) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(cmsgcred), "::", stringify!(cmcred_euid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmcred_gid) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(cmsgcred), "::", stringify!(cmcred_gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmcred_ngroups) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(cmsgcred), + "::", + stringify!(cmcred_ngroups) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmcred_groups) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(cmsgcred), + "::", + stringify!(cmcred_groups) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockcred { + pub sc_uid: uid_t, + pub sc_euid: uid_t, + pub sc_gid: gid_t, + pub sc_egid: gid_t, + pub sc_ngroups: ::std::os::raw::c_int, + pub sc_groups: [gid_t; 1usize], +} +#[test] +fn bindgen_test_layout_sockcred() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(sockcred)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockcred)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_uid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockcred), "::", stringify!(sc_uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_euid) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(sockcred), "::", stringify!(sc_euid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_gid) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sockcred), "::", stringify!(sc_gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_egid) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(sockcred), "::", stringify!(sc_egid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_ngroups) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(sockcred), "::", stringify!(sc_ngroups)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_groups) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(sockcred), "::", stringify!(sc_groups)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockcred2 { + pub sc_version: ::std::os::raw::c_int, + pub sc_pid: pid_t, + pub sc_uid: uid_t, + pub sc_euid: uid_t, + pub sc_gid: gid_t, + pub sc_egid: gid_t, + pub sc_ngroups: ::std::os::raw::c_int, + pub sc_groups: [gid_t; 1usize], +} +#[test] +fn bindgen_test_layout_sockcred2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(sockcred2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockcred2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_version) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockcred2), "::", stringify!(sc_version)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_pid) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(sockcred2), "::", stringify!(sc_pid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_uid) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sockcred2), "::", stringify!(sc_uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_euid) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(sockcred2), "::", stringify!(sc_euid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_gid) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(sockcred2), "::", stringify!(sc_gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_egid) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(sockcred2), "::", stringify!(sc_egid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_ngroups) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(sockcred2), "::", stringify!(sc_ngroups)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sc_groups) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(sockcred2), "::", stringify!(sc_groups)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sock_timestamp_info { + pub st_info_flags: __uint32_t, + pub st_info_pad0: __uint32_t, + pub st_info_rsv: [__uint64_t; 7usize], +} +#[test] +fn bindgen_test_layout_sock_timestamp_info() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(sock_timestamp_info)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sock_timestamp_info)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).st_info_flags) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sock_timestamp_info), + "::", + stringify!(st_info_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).st_info_pad0) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(sock_timestamp_info), + "::", + stringify!(st_info_pad0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).st_info_rsv) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sock_timestamp_info), + "::", + stringify!(st_info_rsv) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct osockaddr { + pub sa_family: ::std::os::raw::c_ushort, + pub sa_data: [::std::os::raw::c_char; 14usize], +} +#[test] +fn bindgen_test_layout_osockaddr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(osockaddr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(osockaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_family) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(osockaddr), "::", stringify!(sa_family)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_data) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(osockaddr), "::", stringify!(sa_data)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct omsghdr { + pub msg_name: *mut ::std::os::raw::c_char, + pub msg_namelen: ::std::os::raw::c_int, + pub msg_iov: *mut iovec, + pub msg_iovlen: ::std::os::raw::c_int, + pub msg_accrights: *mut ::std::os::raw::c_char, + pub msg_accrightslen: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_omsghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(omsghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(omsghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(omsghdr), "::", stringify!(msg_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_namelen) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(omsghdr), "::", stringify!(msg_namelen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iov) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(omsghdr), "::", stringify!(msg_iov)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iovlen) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(omsghdr), "::", stringify!(msg_iovlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_accrights) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(omsghdr), + "::", + stringify!(msg_accrights) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_accrightslen) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(omsghdr), + "::", + stringify!(msg_accrightslen) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sf_hdtr { + pub headers: *mut iovec, + pub hdr_cnt: ::std::os::raw::c_int, + pub trailers: *mut iovec, + pub trl_cnt: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_sf_hdtr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(sf_hdtr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sf_hdtr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).headers) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sf_hdtr), "::", stringify!(headers)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hdr_cnt) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sf_hdtr), "::", stringify!(hdr_cnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).trailers) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(sf_hdtr), "::", stringify!(trailers)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).trl_cnt) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(sf_hdtr), "::", stringify!(trl_cnt)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct mmsghdr { + pub msg_hdr: msghdr, + pub msg_len: isize, +} +#[test] +fn bindgen_test_layout_mmsghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(mmsghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(mmsghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_hdr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(mmsghdr), "::", stringify!(msg_hdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_len) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(mmsghdr), "::", stringify!(msg_len)) + ); +} +extern "C" { + pub fn accept(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr, arg3: *mut socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn bind(arg1: ::std::os::raw::c_int, arg2: *const sockaddr, arg3: socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn connect(arg1: ::std::os::raw::c_int, arg2: *const sockaddr, arg3: socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn accept4( + arg1: ::std::os::raw::c_int, + arg2: *mut sockaddr, + arg3: *mut socklen_t, + arg4: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn bindat( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: *const sockaddr, + arg4: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn connectat( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: *const sockaddr, + arg4: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getpeername(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr, arg3: *mut socklen_t) + -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsockname(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr, arg3: *mut socklen_t) + -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsockopt( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *mut ::std::os::raw::c_void, + arg5: *mut socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn listen(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn recv( + arg1: ::std::os::raw::c_int, + arg2: *mut ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + ) -> isize; +} +extern "C" { + pub fn recvfrom( + arg1: ::std::os::raw::c_int, + arg2: *mut ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + arg5: *mut sockaddr, + arg6: *mut socklen_t, + ) -> isize; +} +extern "C" { + pub fn recvmsg(arg1: ::std::os::raw::c_int, arg2: *mut msghdr, arg3: ::std::os::raw::c_int) -> isize; +} +extern "C" { + pub fn recvmmsg( + arg1: ::std::os::raw::c_int, + arg2: *mut mmsghdr, + arg3: usize, + arg4: ::std::os::raw::c_int, + arg5: *const timespec, + ) -> isize; +} +extern "C" { + pub fn send( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + ) -> isize; +} +extern "C" { + pub fn sendto( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + arg5: *const sockaddr, + arg6: socklen_t, + ) -> isize; +} +extern "C" { + pub fn sendmsg(arg1: ::std::os::raw::c_int, arg2: *const msghdr, arg3: ::std::os::raw::c_int) -> isize; +} +extern "C" { + pub fn sendfile( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: off_t, + arg4: usize, + arg5: *mut sf_hdtr, + arg6: *mut off_t, + arg7: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn sendmmsg(arg1: ::std::os::raw::c_int, arg2: *mut mmsghdr, arg3: usize, arg4: ::std::os::raw::c_int) + -> isize; +} +extern "C" { + pub fn setfib(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setsockopt( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *const ::std::os::raw::c_void, + arg5: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn shutdown(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn sockatmark(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn socket( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn socketpair( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *mut ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_clonereq { + pub ifcr_total: ::std::os::raw::c_int, + pub ifcr_count: ::std::os::raw::c_int, + pub ifcr_buffer: *mut ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_if_clonereq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_clonereq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_clonereq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcr_total) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_clonereq), + "::", + stringify!(ifcr_total) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcr_count) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_clonereq), + "::", + stringify!(ifcr_count) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcr_buffer) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_clonereq), + "::", + stringify!(ifcr_buffer) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct if_data { + pub ifi_type: u8, + pub ifi_physical: u8, + pub ifi_addrlen: u8, + pub ifi_hdrlen: u8, + pub ifi_link_state: u8, + pub ifi_vhid: u8, + pub ifi_datalen: u16, + pub ifi_mtu: u32, + pub ifi_metric: u32, + pub ifi_baudrate: u64, + pub ifi_ipackets: u64, + pub ifi_ierrors: u64, + pub ifi_opackets: u64, + pub ifi_oerrors: u64, + pub ifi_collisions: u64, + pub ifi_ibytes: u64, + pub ifi_obytes: u64, + pub ifi_imcasts: u64, + pub ifi_omcasts: u64, + pub ifi_iqdrops: u64, + pub ifi_oqdrops: u64, + pub ifi_noproto: u64, + pub ifi_hwassist: u64, + pub __ifi_epoch: if_data__bindgen_ty_1, + pub __ifi_lastchange: if_data__bindgen_ty_2, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union if_data__bindgen_ty_1 { + pub tt: time_t, + pub ph: u64, +} +#[test] +fn bindgen_test_layout_if_data__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(if_data__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_data__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tt) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_data__bindgen_ty_1), + "::", + stringify!(tt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ph) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_data__bindgen_ty_1), + "::", + stringify!(ph) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union if_data__bindgen_ty_2 { + pub tv: timeval, + pub ph: if_data__bindgen_ty_2__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_data__bindgen_ty_2__bindgen_ty_1 { + pub ph1: u64, + pub ph2: u64, +} +#[test] +fn bindgen_test_layout_if_data__bindgen_ty_2__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_data__bindgen_ty_2__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_data__bindgen_ty_2__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ph1) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_data__bindgen_ty_2__bindgen_ty_1), + "::", + stringify!(ph1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ph2) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_data__bindgen_ty_2__bindgen_ty_1), + "::", + stringify!(ph2) + ) + ); +} +#[test] +fn bindgen_test_layout_if_data__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_data__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_data__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_data__bindgen_ty_2), + "::", + stringify!(tv) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ph) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_data__bindgen_ty_2), + "::", + stringify!(ph) + ) + ); +} +#[test] +fn bindgen_test_layout_if_data() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 152usize, + concat!("Size of: ", stringify!(if_data)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_type) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_physical) as usize - ptr as usize }, + 1usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_physical)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_addrlen) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_addrlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_hdrlen) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_hdrlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_link_state) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_link_state) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_vhid) as usize - ptr as usize }, + 5usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_vhid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_datalen) as usize - ptr as usize }, + 6usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_datalen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_mtu) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_mtu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_metric) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_metric)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_baudrate) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_baudrate)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ipackets) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_ipackets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ierrors) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_ierrors)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_opackets) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_opackets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_oerrors) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_oerrors)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_collisions) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_collisions) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ibytes) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_ibytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_obytes) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_obytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_imcasts) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_imcasts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_omcasts) as usize - ptr as usize }, + 88usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_omcasts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_iqdrops) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_iqdrops)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_oqdrops) as usize - ptr as usize }, + 104usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_oqdrops)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_noproto) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_noproto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_hwassist) as usize - ptr as usize }, + 120usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_hwassist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ifi_epoch) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(__ifi_epoch)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ifi_lastchange) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(__ifi_lastchange) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct if_msghdr { + pub ifm_msglen: u_short, + pub ifm_version: u_char, + pub ifm_type: u_char, + pub ifm_addrs: ::std::os::raw::c_int, + pub ifm_flags: ::std::os::raw::c_int, + pub ifm_index: u_short, + pub _ifm_spare1: u_short, + pub ifm_data: if_data, +} +#[test] +fn bindgen_test_layout_if_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 168usize, + concat!("Size of: ", stringify!(if_msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_msglen) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_msglen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(if_msghdr), + "::", + stringify!(ifm_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_type) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_addrs) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_addrs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_flags) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_index) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_index)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ifm_spare1) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(if_msghdr), + "::", + stringify!(_ifm_spare1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_data) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_data)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct if_msghdrl { + pub ifm_msglen: u_short, + pub ifm_version: u_char, + pub ifm_type: u_char, + pub ifm_addrs: ::std::os::raw::c_int, + pub ifm_flags: ::std::os::raw::c_int, + pub ifm_index: u_short, + pub _ifm_spare1: u_short, + pub ifm_len: u_short, + pub ifm_data_off: u_short, + pub _ifm_spare2: ::std::os::raw::c_int, + pub ifm_data: if_data, +} +#[test] +fn bindgen_test_layout_if_msghdrl() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 176usize, + concat!("Size of: ", stringify!(if_msghdrl)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_msghdrl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_msghdrl), + "::", + stringify!(ifm_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(if_msghdrl), + "::", + stringify!(ifm_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_type) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(if_msghdrl), "::", stringify!(ifm_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_addrs) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(if_msghdrl), "::", stringify!(ifm_addrs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_flags) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_msghdrl), "::", stringify!(ifm_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_index) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(if_msghdrl), "::", stringify!(ifm_index)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ifm_spare1) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(if_msghdrl), + "::", + stringify!(_ifm_spare1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_len) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_msghdrl), "::", stringify!(ifm_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_data_off) as usize - ptr as usize }, + 18usize, + concat!( + "Offset of field: ", + stringify!(if_msghdrl), + "::", + stringify!(ifm_data_off) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ifm_spare2) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(if_msghdrl), + "::", + stringify!(_ifm_spare2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_data) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(if_msghdrl), "::", stringify!(ifm_data)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifa_msghdr { + pub ifam_msglen: u_short, + pub ifam_version: u_char, + pub ifam_type: u_char, + pub ifam_addrs: ::std::os::raw::c_int, + pub ifam_flags: ::std::os::raw::c_int, + pub ifam_index: u_short, + pub _ifam_spare1: u_short, + pub ifam_metric: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ifa_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(ifa_msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifa_msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_type) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(ifa_msghdr), "::", stringify!(ifam_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_addrs) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_addrs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_flags) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_index) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ifam_spare1) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(_ifam_spare1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_metric) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_metric) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifa_msghdrl { + pub ifam_msglen: u_short, + pub ifam_version: u_char, + pub ifam_type: u_char, + pub ifam_addrs: ::std::os::raw::c_int, + pub ifam_flags: ::std::os::raw::c_int, + pub ifam_index: u_short, + pub _ifam_spare1: u_short, + pub ifam_len: u_short, + pub ifam_data_off: u_short, + pub ifam_metric: ::std::os::raw::c_int, + pub ifam_data: if_data, +} +#[test] +fn bindgen_test_layout_ifa_msghdrl() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 176usize, + concat!("Size of: ", stringify!(ifa_msghdrl)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifa_msghdrl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(ifam_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(ifam_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_type) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(ifam_type) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_addrs) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(ifam_addrs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_flags) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(ifam_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_index) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(ifam_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ifam_spare1) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(_ifam_spare1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_len) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifa_msghdrl), "::", stringify!(ifam_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_data_off) as usize - ptr as usize }, + 18usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(ifam_data_off) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_metric) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(ifam_metric) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_data) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdrl), + "::", + stringify!(ifam_data) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifma_msghdr { + pub ifmam_msglen: u_short, + pub ifmam_version: u_char, + pub ifmam_type: u_char, + pub ifmam_addrs: ::std::os::raw::c_int, + pub ifmam_flags: ::std::os::raw::c_int, + pub ifmam_index: u_short, + pub _ifmam_spare1: u_short, +} +#[test] +fn bindgen_test_layout_ifma_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifma_msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifma_msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifmam_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifma_msghdr), + "::", + stringify!(ifmam_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifmam_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(ifma_msghdr), + "::", + stringify!(ifmam_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifmam_type) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(ifma_msghdr), + "::", + stringify!(ifmam_type) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifmam_addrs) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ifma_msghdr), + "::", + stringify!(ifmam_addrs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifmam_flags) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ifma_msghdr), + "::", + stringify!(ifmam_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifmam_index) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(ifma_msghdr), + "::", + stringify!(ifmam_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ifmam_spare1) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(ifma_msghdr), + "::", + stringify!(_ifmam_spare1) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_announcemsghdr { + pub ifan_msglen: u_short, + pub ifan_version: u_char, + pub ifan_type: u_char, + pub ifan_index: u_short, + pub ifan_name: [::std::os::raw::c_char; 16usize], + pub ifan_what: u_short, +} +#[test] +fn bindgen_test_layout_if_announcemsghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(if_announcemsghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(if_announcemsghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_type) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_type) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_index) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_name) as usize - ptr as usize }, + 6usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_what) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_what) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifreq_buffer { + pub length: usize, + pub buffer: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout_ifreq_buffer() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifreq_buffer)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifreq_buffer)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).length) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifreq_buffer), "::", stringify!(length)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).buffer) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(ifreq_buffer), "::", stringify!(buffer)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifreq_nv_req { + pub buf_length: u_int, + pub length: u_int, + pub buffer: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout_ifreq_nv_req() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifreq_nv_req)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifreq_nv_req)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).buf_length) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq_nv_req), + "::", + stringify!(buf_length) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).length) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(ifreq_nv_req), "::", stringify!(length)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).buffer) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(ifreq_nv_req), "::", stringify!(buffer)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifreq { + pub ifr_name: [::std::os::raw::c_char; 16usize], + pub ifr_ifru: ifreq__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union ifreq__bindgen_ty_1 { + pub ifru_addr: sockaddr, + pub ifru_dstaddr: sockaddr, + pub ifru_broadaddr: sockaddr, + pub ifru_buffer: ifreq_buffer, + pub ifru_flags: [::std::os::raw::c_short; 2usize], + pub ifru_index: ::std::os::raw::c_short, + pub ifru_jid: ::std::os::raw::c_int, + pub ifru_metric: ::std::os::raw::c_int, + pub ifru_mtu: ::std::os::raw::c_int, + pub ifru_phys: ::std::os::raw::c_int, + pub ifru_media: ::std::os::raw::c_int, + pub ifru_data: caddr_t, + pub ifru_cap: [::std::os::raw::c_int; 2usize], + pub ifru_fib: u_int, + pub ifru_vlan_pcp: u_char, + pub ifru_nv: ifreq_nv_req, +} +#[test] +fn bindgen_test_layout_ifreq__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifreq__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifreq__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_dstaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_dstaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_broadaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_broadaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_buffer) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_buffer) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_flags) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_index) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_jid) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_jid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_metric) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_metric) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_mtu) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_mtu) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_phys) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_phys) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_media) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_media) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_data) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_data) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_cap) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_cap) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_fib) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_fib) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_vlan_pcp) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_vlan_pcp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_nv) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_nv) + ) + ); +} +#[test] +fn bindgen_test_layout_ifreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(ifreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifr_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifreq), "::", stringify!(ifr_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifr_ifru) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifreq), "::", stringify!(ifr_ifru)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifaliasreq { + pub ifra_name: [::std::os::raw::c_char; 16usize], + pub ifra_addr: sockaddr, + pub ifra_broadaddr: sockaddr, + pub ifra_mask: sockaddr, + pub ifra_vhid: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ifaliasreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 68usize, + concat!("Size of: ", stringify!(ifaliasreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifaliasreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifaliasreq), "::", stringify!(ifra_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_addr) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifaliasreq), "::", stringify!(ifra_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_broadaddr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(ifaliasreq), + "::", + stringify!(ifra_broadaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_mask) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(ifaliasreq), "::", stringify!(ifra_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_vhid) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(ifaliasreq), "::", stringify!(ifra_vhid)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct oifaliasreq { + pub ifra_name: [::std::os::raw::c_char; 16usize], + pub ifra_addr: sockaddr, + pub ifra_broadaddr: sockaddr, + pub ifra_mask: sockaddr, +} +#[test] +fn bindgen_test_layout_oifaliasreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(oifaliasreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(oifaliasreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(oifaliasreq), + "::", + stringify!(ifra_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_addr) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(oifaliasreq), + "::", + stringify!(ifra_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_broadaddr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(oifaliasreq), + "::", + stringify!(ifra_broadaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_mask) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(oifaliasreq), + "::", + stringify!(ifra_mask) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifmediareq { + pub ifm_name: [::std::os::raw::c_char; 16usize], + pub ifm_current: ::std::os::raw::c_int, + pub ifm_mask: ::std::os::raw::c_int, + pub ifm_status: ::std::os::raw::c_int, + pub ifm_active: ::std::os::raw::c_int, + pub ifm_count: ::std::os::raw::c_int, + pub ifm_ulist: *mut ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ifmediareq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(ifmediareq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifmediareq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifmediareq), "::", stringify!(ifm_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_current) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ifmediareq), + "::", + stringify!(ifm_current) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_mask) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(ifmediareq), "::", stringify!(ifm_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_status) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(ifmediareq), + "::", + stringify!(ifm_status) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_active) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(ifmediareq), + "::", + stringify!(ifm_active) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_count) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(ifmediareq), "::", stringify!(ifm_count)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_ulist) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(ifmediareq), "::", stringify!(ifm_ulist)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifdrv { + pub ifd_name: [::std::os::raw::c_char; 16usize], + pub ifd_cmd: ::std::os::raw::c_ulong, + pub ifd_len: usize, + pub ifd_data: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout_ifdrv() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(ifdrv)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifdrv)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifd_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifdrv), "::", stringify!(ifd_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifd_cmd) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifdrv), "::", stringify!(ifd_cmd)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifd_len) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(ifdrv), "::", stringify!(ifd_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifd_data) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(ifdrv), "::", stringify!(ifd_data)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifstat { + pub ifs_name: [::std::os::raw::c_char; 16usize], + pub ascii: [::std::os::raw::c_char; 801usize], +} +#[test] +fn bindgen_test_layout_ifstat() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 817usize, + concat!("Size of: ", stringify!(ifstat)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(ifstat)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifs_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifstat), "::", stringify!(ifs_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ascii) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifstat), "::", stringify!(ascii)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifconf { + pub ifc_len: ::std::os::raw::c_int, + pub ifc_ifcu: ifconf__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union ifconf__bindgen_ty_1 { + pub ifcu_buf: caddr_t, + pub ifcu_req: *mut ifreq, +} +#[test] +fn bindgen_test_layout_ifconf__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(ifconf__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifconf__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcu_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifconf__bindgen_ty_1), + "::", + stringify!(ifcu_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcu_req) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifconf__bindgen_ty_1), + "::", + stringify!(ifcu_req) + ) + ); +} +#[test] +fn bindgen_test_layout_ifconf() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifconf)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifconf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifc_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifconf), "::", stringify!(ifc_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifc_ifcu) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(ifconf), "::", stringify!(ifc_ifcu)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifg_req { + pub ifgrq_ifgrqu: ifg_req__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union ifg_req__bindgen_ty_1 { + pub ifgrqu_group: [::std::os::raw::c_char; 16usize], + pub ifgrqu_member: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_ifg_req__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifg_req__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(ifg_req__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgrqu_group) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifg_req__bindgen_ty_1), + "::", + stringify!(ifgrqu_group) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgrqu_member) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifg_req__bindgen_ty_1), + "::", + stringify!(ifgrqu_member) + ) + ); +} +#[test] +fn bindgen_test_layout_ifg_req() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifg_req)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(ifg_req)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgrq_ifgrqu) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifg_req), "::", stringify!(ifgrq_ifgrqu)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifgroupreq { + pub ifgr_name: [::std::os::raw::c_char; 16usize], + pub ifgr_len: u_int, + pub ifgr_ifgru: ifgroupreq__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union ifgroupreq__bindgen_ty_1 { + pub ifgru_group: [::std::os::raw::c_char; 16usize], + pub ifgru_groups: *mut ifg_req, +} +#[test] +fn bindgen_test_layout_ifgroupreq__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifgroupreq__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifgroupreq__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgru_group) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifgroupreq__bindgen_ty_1), + "::", + stringify!(ifgru_group) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgru_groups) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifgroupreq__bindgen_ty_1), + "::", + stringify!(ifgru_groups) + ) + ); +} +#[test] +fn bindgen_test_layout_ifgroupreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(ifgroupreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifgroupreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgr_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifgroupreq), "::", stringify!(ifgr_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgr_len) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifgroupreq), "::", stringify!(ifgr_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgr_ifgru) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(ifgroupreq), + "::", + stringify!(ifgr_ifgru) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifi2creq { + pub dev_addr: u8, + pub offset: u8, + pub len: u8, + pub spare0: u8, + pub spare1: u32, + pub data: [u8; 8usize], +} +#[test] +fn bindgen_test_layout_ifi2creq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifi2creq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifi2creq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dev_addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifi2creq), "::", stringify!(dev_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).offset) as usize - ptr as usize }, + 1usize, + concat!("Offset of field: ", stringify!(ifi2creq), "::", stringify!(offset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).len) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(ifi2creq), "::", stringify!(len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).spare0) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(ifi2creq), "::", stringify!(spare0)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).spare1) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(ifi2creq), "::", stringify!(spare1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).data) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(ifi2creq), "::", stringify!(data)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifrsskey { + pub ifrk_name: [::std::os::raw::c_char; 16usize], + pub ifrk_func: u8, + pub ifrk_spare0: u8, + pub ifrk_keylen: u16, + pub ifrk_key: [u8; 128usize], +} +#[test] +fn bindgen_test_layout_ifrsskey() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 148usize, + concat!("Size of: ", stringify!(ifrsskey)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(ifrsskey)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrk_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifrsskey), "::", stringify!(ifrk_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrk_func) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifrsskey), "::", stringify!(ifrk_func)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrk_spare0) as usize - ptr as usize }, + 17usize, + concat!("Offset of field: ", stringify!(ifrsskey), "::", stringify!(ifrk_spare0)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrk_keylen) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(ifrsskey), "::", stringify!(ifrk_keylen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrk_key) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(ifrsskey), "::", stringify!(ifrk_key)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifrsshash { + pub ifrh_name: [::std::os::raw::c_char; 16usize], + pub ifrh_func: u8, + pub ifrh_spare0: u8, + pub ifrh_spare1: u16, + pub ifrh_types: u32, +} +#[test] +fn bindgen_test_layout_ifrsshash() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(ifrsshash)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifrsshash)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrh_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifrsshash), "::", stringify!(ifrh_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrh_func) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifrsshash), "::", stringify!(ifrh_func)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrh_spare0) as usize - ptr as usize }, + 17usize, + concat!( + "Offset of field: ", + stringify!(ifrsshash), + "::", + stringify!(ifrh_spare0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrh_spare1) as usize - ptr as usize }, + 18usize, + concat!( + "Offset of field: ", + stringify!(ifrsshash), + "::", + stringify!(ifrh_spare1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrh_types) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(ifrsshash), "::", stringify!(ifrh_types)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifdownreason { + pub ifdr_name: [::std::os::raw::c_char; 16usize], + pub ifdr_reason: u32, + pub ifdr_vendor: u32, + pub ifdr_msg: [::std::os::raw::c_char; 64usize], +} +#[test] +fn bindgen_test_layout_ifdownreason() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 88usize, + concat!("Size of: ", stringify!(ifdownreason)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifdownreason)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifdr_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifdownreason), + "::", + stringify!(ifdr_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifdr_reason) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ifdownreason), + "::", + stringify!(ifdr_reason) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifdr_vendor) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(ifdownreason), + "::", + stringify!(ifdr_vendor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifdr_msg) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(ifdownreason), + "::", + stringify!(ifdr_msg) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifnet { + _unused: [u8; 0], +} +pub type if_t = *mut ifnet; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_nameindex { + pub if_index: ::std::os::raw::c_uint, + pub if_name: *mut ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_if_nameindex() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_nameindex)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_nameindex)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_index) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_nameindex), + "::", + stringify!(if_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_name) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_nameindex), "::", stringify!(if_name)) + ); +} +extern "C" { + pub fn if_freenameindex(arg1: *mut if_nameindex); +} +extern "C" { + pub fn if_indextoname( + arg1: ::std::os::raw::c_uint, + arg2: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn if_nameindex() -> *mut if_nameindex; +} +extern "C" { + pub fn if_nametoindex(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_uint; +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct ether_header { + pub ether_dhost: [u_char; 6usize], + pub ether_shost: [u_char; 6usize], + pub ether_type: u_short, +} +#[test] +fn bindgen_test_layout_ether_header() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 14usize, + concat!("Size of: ", stringify!(ether_header)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(ether_header)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ether_dhost) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ether_header), + "::", + stringify!(ether_dhost) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ether_shost) as usize - ptr as usize }, + 6usize, + concat!( + "Offset of field: ", + stringify!(ether_header), + "::", + stringify!(ether_shost) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ether_type) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(ether_header), + "::", + stringify!(ether_type) + ) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct ether_addr { + pub octet: [u_char; 6usize], +} +#[test] +fn bindgen_test_layout_ether_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 6usize, + concat!("Size of: ", stringify!(ether_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(ether_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).octet) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ether_addr), "::", stringify!(octet)) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct ether_vlan_header { + pub evl_dhost: [u8; 6usize], + pub evl_shost: [u8; 6usize], + pub evl_encap_proto: u16, + pub evl_tag: u16, + pub evl_proto: u16, +} +#[test] +fn bindgen_test_layout_ether_vlan_header() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 18usize, + concat!("Size of: ", stringify!(ether_vlan_header)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(ether_vlan_header)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).evl_dhost) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ether_vlan_header), + "::", + stringify!(evl_dhost) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).evl_shost) as usize - ptr as usize }, + 6usize, + concat!( + "Offset of field: ", + stringify!(ether_vlan_header), + "::", + stringify!(evl_shost) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).evl_encap_proto) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(ether_vlan_header), + "::", + stringify!(evl_encap_proto) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).evl_tag) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(ether_vlan_header), + "::", + stringify!(evl_tag) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).evl_proto) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ether_vlan_header), + "::", + stringify!(evl_proto) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct mbuf { + _unused: [u8; 0], +} +extern "C" { + pub fn ether_bpf_mtap_if(ifp: *mut ifnet, m: *mut mbuf); +} +extern "C" { + pub fn ether_aton(arg1: *const ::std::os::raw::c_char) -> *mut ether_addr; +} +extern "C" { + pub fn ether_aton_r(arg1: *const ::std::os::raw::c_char, arg2: *mut ether_addr) -> *mut ether_addr; +} +extern "C" { + pub fn ether_hostton(arg1: *const ::std::os::raw::c_char, arg2: *mut ether_addr) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ether_line( + arg1: *const ::std::os::raw::c_char, + arg2: *mut ether_addr, + arg3: *mut ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ether_ntoa(arg1: *const ether_addr) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ether_ntoa_r(arg1: *const ether_addr, arg2: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ether_ntohost(arg1: *mut ::std::os::raw::c_char, arg2: *const ether_addr) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_node { + pub rn_mklist: *mut radix_mask, + pub rn_parent: *mut radix_node, + pub rn_bit: ::std::os::raw::c_short, + pub rn_bmask: ::std::os::raw::c_char, + pub rn_flags: u_char, + pub rn_u: radix_node__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union radix_node__bindgen_ty_1 { + pub rn_leaf: radix_node__bindgen_ty_1__bindgen_ty_1, + pub rn_node: radix_node__bindgen_ty_1__bindgen_ty_2, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct radix_node__bindgen_ty_1__bindgen_ty_1 { + pub rn_Key: caddr_t, + pub rn_Mask: caddr_t, + pub rn_Dupedkey: *mut radix_node, +} +#[test] +fn bindgen_test_layout_radix_node__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Key) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rn_Key) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Mask) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rn_Mask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Dupedkey) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rn_Dupedkey) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct radix_node__bindgen_ty_1__bindgen_ty_2 { + pub rn_Off: ::std::os::raw::c_int, + pub rn_L: *mut radix_node, + pub rn_R: *mut radix_node, +} +#[test] +fn bindgen_test_layout_radix_node__bindgen_ty_1__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Off) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(rn_Off) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_L) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(rn_L) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_R) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(rn_R) + ) + ); +} +#[test] +fn bindgen_test_layout_radix_node__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(radix_node__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_leaf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1), + "::", + stringify!(rn_leaf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_node) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1), + "::", + stringify!(rn_node) + ) + ); +} +#[test] +fn bindgen_test_layout_radix_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(radix_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_mklist) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_mklist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_parent) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_bit) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_bit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_bmask) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_bmask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_flags) as usize - ptr as usize }, + 19usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_u) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_u)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_mask { + pub rm_bit: ::std::os::raw::c_short, + pub rm_unused: ::std::os::raw::c_char, + pub rm_flags: u_char, + pub rm_mklist: *mut radix_mask, + pub rm_rmu: radix_mask__bindgen_ty_1, + pub rm_refs: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union radix_mask__bindgen_ty_1 { + pub rmu_mask: caddr_t, + pub rmu_leaf: *mut radix_node, +} +#[test] +fn bindgen_test_layout_radix_mask__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(radix_mask__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_mask__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmu_mask) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_mask__bindgen_ty_1), + "::", + stringify!(rmu_mask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmu_leaf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_mask__bindgen_ty_1), + "::", + stringify!(rmu_leaf) + ) + ); +} +#[test] +fn bindgen_test_layout_radix_mask() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(radix_mask)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_bit) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_bit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_unused) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_unused)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_flags) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_mklist) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_mklist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_rmu) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_rmu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_refs) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_refs)) + ); +} +pub type walktree_f_t = ::std::option::Option< + unsafe extern "C" fn(arg1: *mut radix_node, arg2: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int, +>; +pub type rn_matchaddr_f_t = ::std::option::Option< + unsafe extern "C" fn(v: *const ::std::os::raw::c_void, head: *mut radix_head) -> *mut radix_node, +>; +pub type rn_addaddr_f_t = ::std::option::Option< + unsafe extern "C" fn( + v: *mut ::std::os::raw::c_void, + mask: *const ::std::os::raw::c_void, + head: *mut radix_head, + nodes: *mut radix_node, + ) -> *mut radix_node, +>; +pub type rn_deladdr_f_t = ::std::option::Option< + unsafe extern "C" fn( + v: *const ::std::os::raw::c_void, + mask: *const ::std::os::raw::c_void, + head: *mut radix_head, + ) -> *mut radix_node, +>; +pub type rn_lookup_f_t = ::std::option::Option< + unsafe extern "C" fn( + v: *const ::std::os::raw::c_void, + mask: *const ::std::os::raw::c_void, + head: *mut radix_head, + ) -> *mut radix_node, +>; +pub type rn_walktree_t = ::std::option::Option< + unsafe extern "C" fn( + head: *mut radix_head, + f: walktree_f_t, + w: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int, +>; +pub type rn_walktree_from_t = ::std::option::Option< + unsafe extern "C" fn( + head: *mut radix_head, + a: *mut ::std::os::raw::c_void, + m: *mut ::std::os::raw::c_void, + f: walktree_f_t, + w: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int, +>; +pub type rn_close_t = ::std::option::Option; +extern "C" { + pub fn rn_nextprefix(rn: *mut radix_node) -> *mut radix_node; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct radix_head { + pub rnh_treetop: *mut radix_node, + pub rnh_masks: *mut radix_mask_head, +} +#[test] +fn bindgen_test_layout_radix_head() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(radix_head)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_head)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_treetop) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_head), + "::", + stringify!(rnh_treetop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_masks) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(radix_head), "::", stringify!(rnh_masks)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_node_head { + pub rh: radix_head, + pub rnh_matchaddr: rn_matchaddr_f_t, + pub rnh_addaddr: rn_addaddr_f_t, + pub rnh_deladdr: rn_deladdr_f_t, + pub rnh_lookup: rn_lookup_f_t, + pub rnh_walktree: rn_walktree_t, + pub rnh_walktree_from: rn_walktree_from_t, + pub rnh_close: rn_close_t, + pub rnh_nodes: [radix_node; 3usize], +} +#[test] +fn bindgen_test_layout_radix_node_head() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 216usize, + concat!("Size of: ", stringify!(radix_node_head)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node_head)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rh) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(radix_node_head), "::", stringify!(rh)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_matchaddr) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_matchaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_addaddr) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_addaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_deladdr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_deladdr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_lookup) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_lookup) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_walktree) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_walktree) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_walktree_from) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_walktree_from) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_close) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_close) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_nodes) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_nodes) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_mask_head { + pub head: radix_head, + pub mask_nodes: [radix_node; 3usize], +} +#[test] +fn bindgen_test_layout_radix_mask_head() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 160usize, + concat!("Size of: ", stringify!(radix_mask_head)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_mask_head)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).head) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(radix_mask_head), "::", stringify!(head)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mask_nodes) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_mask_head), + "::", + stringify!(mask_nodes) + ) + ); +} +extern "C" { + pub fn rn_inithead_internal(rh: *mut radix_head, base_nodes: *mut radix_node, off: ::std::os::raw::c_int); +} +extern "C" { + pub fn rn_inithead(arg1: *mut *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rn_detachhead(arg1: *mut *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rn_refines( + arg1: *const ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rn_addroute( + arg1: *mut ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_void, + arg3: *mut radix_head, + arg4: *mut radix_node, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_delete( + arg1: *const ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_void, + arg3: *mut radix_head, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_lookup( + v_arg: *const ::std::os::raw::c_void, + m_arg: *const ::std::os::raw::c_void, + head: *mut radix_head, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_match(arg1: *const ::std::os::raw::c_void, arg2: *mut radix_head) -> *mut radix_node; +} +extern "C" { + pub fn rn_walktree_from( + h: *mut radix_head, + a: *mut ::std::os::raw::c_void, + m: *mut ::std::os::raw::c_void, + f: walktree_f_t, + w: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rn_walktree( + arg1: *mut radix_head, + arg2: walktree_f_t, + arg3: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct in_addr { + pub s_addr: in_addr_t, +} +#[test] +fn bindgen_test_layout_in_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(in_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).s_addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(in_addr), "::", stringify!(s_addr)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_in { + pub sin_len: u8, + pub sin_family: sa_family_t, + pub sin_port: in_port_t, + pub sin_addr: in_addr, + pub sin_zero: [::std::os::raw::c_char; 8usize], +} +#[test] +fn bindgen_test_layout_sockaddr_in() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sockaddr_in)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_in)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in), + "::", + stringify!(sin_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_port) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_addr) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_zero) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_zero)) + ); +} +extern "C" { + pub fn htonl(arg1: u32) -> u32; +} +extern "C" { + pub fn htons(arg1: u16) -> u16; +} +extern "C" { + pub fn ntohl(arg1: u32) -> u32; +} +extern "C" { + pub fn ntohs(arg1: u16) -> u16; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_mreq { + pub imr_multiaddr: in_addr, + pub imr_interface: in_addr, +} +#[test] +fn bindgen_test_layout_ip_mreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(ip_mreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_mreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq), + "::", + stringify!(imr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_interface) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq), + "::", + stringify!(imr_interface) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_mreqn { + pub imr_multiaddr: in_addr, + pub imr_address: in_addr, + pub imr_ifindex: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ip_mreqn() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(ip_mreqn)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_mreqn)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip_mreqn), + "::", + stringify!(imr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_address) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(ip_mreqn), "::", stringify!(imr_address)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_ifindex) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(ip_mreqn), "::", stringify!(imr_ifindex)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_mreq_source { + pub imr_multiaddr: in_addr, + pub imr_sourceaddr: in_addr, + pub imr_interface: in_addr, +} +#[test] +fn bindgen_test_layout_ip_mreq_source() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(ip_mreq_source)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_mreq_source)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq_source), + "::", + stringify!(imr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_sourceaddr) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq_source), + "::", + stringify!(imr_sourceaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_interface) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq_source), + "::", + stringify!(imr_interface) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct group_req { + pub gr_interface: u32, + pub gr_group: sockaddr_storage, +} +#[test] +fn bindgen_test_layout_group_req() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 136usize, + concat!("Size of: ", stringify!(group_req)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(group_req)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gr_interface) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(group_req), + "::", + stringify!(gr_interface) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gr_group) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(group_req), "::", stringify!(gr_group)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct group_source_req { + pub gsr_interface: u32, + pub gsr_group: sockaddr_storage, + pub gsr_source: sockaddr_storage, +} +#[test] +fn bindgen_test_layout_group_source_req() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 264usize, + concat!("Size of: ", stringify!(group_source_req)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(group_source_req)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gsr_interface) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(group_source_req), + "::", + stringify!(gsr_interface) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gsr_group) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(group_source_req), + "::", + stringify!(gsr_group) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gsr_source) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(group_source_req), + "::", + stringify!(gsr_source) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __msfilterreq { + pub msfr_ifindex: u32, + pub msfr_fmode: u32, + pub msfr_nsrcs: u32, + pub msfr_group: sockaddr_storage, + pub msfr_srcs: *mut sockaddr_storage, +} +#[test] +fn bindgen_test_layout___msfilterreq() { + const UNINIT: ::std::mem::MaybeUninit<__msfilterreq> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__msfilterreq>(), + 152usize, + concat!("Size of: ", stringify!(__msfilterreq)) + ); + assert_eq!( + ::std::mem::align_of::<__msfilterreq>(), + 8usize, + concat!("Alignment of ", stringify!(__msfilterreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_ifindex) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_ifindex) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_fmode) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_fmode) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_nsrcs) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_nsrcs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_group) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_group) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_srcs) as usize - ptr as usize }, + 144usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_srcs) + ) + ); +} +extern "C" { + pub fn setipv4sourcefilter( + arg1: ::std::os::raw::c_int, + arg2: in_addr, + arg3: in_addr, + arg4: u32, + arg5: u32, + arg6: *mut in_addr, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getipv4sourcefilter( + arg1: ::std::os::raw::c_int, + arg2: in_addr, + arg3: in_addr, + arg4: *mut u32, + arg5: *mut u32, + arg6: *mut in_addr, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setsourcefilter( + arg1: ::std::os::raw::c_int, + arg2: u32, + arg3: *mut sockaddr, + arg4: socklen_t, + arg5: u32, + arg6: u32, + arg7: *mut sockaddr_storage, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsourcefilter( + arg1: ::std::os::raw::c_int, + arg2: u32, + arg3: *mut sockaddr, + arg4: socklen_t, + arg5: *mut u32, + arg6: *mut u32, + arg7: *mut sockaddr_storage, + ) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct in6_addr { + pub __u6_addr: in6_addr__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union in6_addr__bindgen_ty_1 { + pub __u6_addr8: [u8; 16usize], + pub __u6_addr16: [u16; 8usize], + pub __u6_addr32: [u32; 4usize], +} +#[test] +fn bindgen_test_layout_in6_addr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(in6_addr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in6_addr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_addr__bindgen_ty_1), + "::", + stringify!(__u6_addr8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr16) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_addr__bindgen_ty_1), + "::", + stringify!(__u6_addr16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr32) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_addr__bindgen_ty_1), + "::", + stringify!(__u6_addr32) + ) + ); +} +#[test] +fn bindgen_test_layout_in6_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(in6_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in6_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(in6_addr), "::", stringify!(__u6_addr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct sockaddr_in6 { + pub sin6_len: u8, + pub sin6_family: sa_family_t, + pub sin6_port: in_port_t, + pub sin6_flowinfo: u32, + pub sin6_addr: in6_addr, + pub sin6_scope_id: u32, +} +#[test] +fn bindgen_test_layout_sockaddr_in6() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 28usize, + concat!("Size of: ", stringify!(sockaddr_in6)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_in6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_port) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_port) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_flowinfo) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_flowinfo) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_addr) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_scope_id) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_scope_id) + ) + ); +} +extern "C" { + pub static in6addr_any: in6_addr; +} +extern "C" { + pub static in6addr_loopback: in6_addr; +} +extern "C" { + pub static in6addr_nodelocal_allnodes: in6_addr; +} +extern "C" { + pub static in6addr_linklocal_allnodes: in6_addr; +} +extern "C" { + pub static in6addr_linklocal_allrouters: in6_addr; +} +extern "C" { + pub static in6addr_linklocal_allv2routers: in6_addr; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct nhop_object { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct route_in6 { + pub ro_nh: *mut nhop_object, + pub ro_lle: *mut llentry, + pub ro_prepend: *mut ::std::os::raw::c_char, + pub ro_plen: u16, + pub ro_flags: u16, + pub ro_mtu: u16, + pub spare: u16, + pub ro_dst: sockaddr_in6, +} +#[test] +fn bindgen_test_layout_route_in6() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(route_in6)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(route_in6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_nh) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(route_in6), "::", stringify!(ro_nh)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_lle) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(route_in6), "::", stringify!(ro_lle)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_prepend) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(route_in6), "::", stringify!(ro_prepend)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_plen) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(route_in6), "::", stringify!(ro_plen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_flags) as usize - ptr as usize }, + 26usize, + concat!("Offset of field: ", stringify!(route_in6), "::", stringify!(ro_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_mtu) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(route_in6), "::", stringify!(ro_mtu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).spare) as usize - ptr as usize }, + 30usize, + concat!("Offset of field: ", stringify!(route_in6), "::", stringify!(spare)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_dst) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(route_in6), "::", stringify!(ro_dst)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ipv6_mreq { + pub ipv6mr_multiaddr: in6_addr, + pub ipv6mr_interface: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_ipv6_mreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(ipv6_mreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ipv6_mreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipv6mr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ipv6_mreq), + "::", + stringify!(ipv6mr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipv6mr_interface) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ipv6_mreq), + "::", + stringify!(ipv6mr_interface) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct in6_pktinfo { + pub ipi6_addr: in6_addr, + pub ipi6_ifindex: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_in6_pktinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(in6_pktinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in6_pktinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipi6_addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_pktinfo), + "::", + stringify!(ipi6_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipi6_ifindex) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(in6_pktinfo), + "::", + stringify!(ipi6_ifindex) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ip6_mtuinfo { + pub ip6m_addr: sockaddr_in6, + pub ip6m_mtu: u32, +} +#[test] +fn bindgen_test_layout_ip6_mtuinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(ip6_mtuinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip6_mtuinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip6m_addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip6_mtuinfo), + "::", + stringify!(ip6m_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip6m_mtu) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(ip6_mtuinfo), "::", stringify!(ip6m_mtu)) + ); +} +extern "C" { + pub fn inet6_option_space(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_option_init( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut *mut cmsghdr, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_option_append( + arg1: *mut cmsghdr, + arg2: *const u8, + arg3: ::std::os::raw::c_int, + arg4: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_option_alloc( + arg1: *mut cmsghdr, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: ::std::os::raw::c_int, + ) -> *mut u8; +} +extern "C" { + pub fn inet6_option_next(arg1: *const cmsghdr, arg2: *mut *mut u8) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_option_find( + arg1: *const cmsghdr, + arg2: *mut *mut u8, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rthdr_space(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> usize; +} +extern "C" { + pub fn inet6_rthdr_init(arg1: *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_int) -> *mut cmsghdr; +} +extern "C" { + pub fn inet6_rthdr_add( + arg1: *mut cmsghdr, + arg2: *const in6_addr, + arg3: ::std::os::raw::c_uint, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rthdr_lasthop(arg1: *mut cmsghdr, arg2: ::std::os::raw::c_uint) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rthdr_segments(arg1: *const cmsghdr) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rthdr_getaddr(arg1: *mut cmsghdr, arg2: ::std::os::raw::c_int) -> *mut in6_addr; +} +extern "C" { + pub fn inet6_rthdr_getflags(arg1: *const cmsghdr, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_init(arg1: *mut ::std::os::raw::c_void, arg2: socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_append( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: u8, + arg5: socklen_t, + arg6: u8, + arg7: *mut *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_finish( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_set_val( + arg1: *mut ::std::os::raw::c_void, + arg2: ::std::os::raw::c_int, + arg3: *mut ::std::os::raw::c_void, + arg4: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_next( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: *mut u8, + arg5: *mut socklen_t, + arg6: *mut *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_find( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: u8, + arg5: *mut socklen_t, + arg6: *mut *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_get_val( + arg1: *mut ::std::os::raw::c_void, + arg2: ::std::os::raw::c_int, + arg3: *mut ::std::os::raw::c_void, + arg4: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_space(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> socklen_t; +} +extern "C" { + pub fn inet6_rth_init( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn inet6_rth_add(arg1: *mut ::std::os::raw::c_void, arg2: *const in6_addr) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_reverse( + arg1: *const ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_segments(arg1: *const ::std::os::raw::c_void) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_getaddr(arg1: *const ::std::os::raw::c_void, arg2: ::std::os::raw::c_int) -> *mut in6_addr; +} +pub const PF_INOUT: _bindgen_ty_1 = 0; +pub const PF_IN: _bindgen_ty_1 = 1; +pub const PF_OUT: _bindgen_ty_1 = 2; +pub type _bindgen_ty_1 = ::std::os::raw::c_uint; +pub const PF_PASS: _bindgen_ty_2 = 0; +pub const PF_DROP: _bindgen_ty_2 = 1; +pub const PF_SCRUB: _bindgen_ty_2 = 2; +pub const PF_NOSCRUB: _bindgen_ty_2 = 3; +pub const PF_NAT: _bindgen_ty_2 = 4; +pub const PF_NONAT: _bindgen_ty_2 = 5; +pub const PF_BINAT: _bindgen_ty_2 = 6; +pub const PF_NOBINAT: _bindgen_ty_2 = 7; +pub const PF_RDR: _bindgen_ty_2 = 8; +pub const PF_NORDR: _bindgen_ty_2 = 9; +pub const PF_SYNPROXY_DROP: _bindgen_ty_2 = 10; +pub const PF_DEFER: _bindgen_ty_2 = 11; +pub const PF_MATCH: _bindgen_ty_2 = 12; +pub type _bindgen_ty_2 = ::std::os::raw::c_uint; +pub const PF_RULESET_SCRUB: _bindgen_ty_3 = 0; +pub const PF_RULESET_FILTER: _bindgen_ty_3 = 1; +pub const PF_RULESET_NAT: _bindgen_ty_3 = 2; +pub const PF_RULESET_BINAT: _bindgen_ty_3 = 3; +pub const PF_RULESET_RDR: _bindgen_ty_3 = 4; +pub const PF_RULESET_MAX: _bindgen_ty_3 = 5; +pub type _bindgen_ty_3 = ::std::os::raw::c_uint; +pub const PF_OP_NONE: _bindgen_ty_4 = 0; +pub const PF_OP_IRG: _bindgen_ty_4 = 1; +pub const PF_OP_EQ: _bindgen_ty_4 = 2; +pub const PF_OP_NE: _bindgen_ty_4 = 3; +pub const PF_OP_LT: _bindgen_ty_4 = 4; +pub const PF_OP_LE: _bindgen_ty_4 = 5; +pub const PF_OP_GT: _bindgen_ty_4 = 6; +pub const PF_OP_GE: _bindgen_ty_4 = 7; +pub const PF_OP_XRG: _bindgen_ty_4 = 8; +pub const PF_OP_RRG: _bindgen_ty_4 = 9; +pub type _bindgen_ty_4 = ::std::os::raw::c_uint; +pub const PF_DEBUG_NONE: _bindgen_ty_5 = 0; +pub const PF_DEBUG_URGENT: _bindgen_ty_5 = 1; +pub const PF_DEBUG_MISC: _bindgen_ty_5 = 2; +pub const PF_DEBUG_NOISY: _bindgen_ty_5 = 3; +pub type _bindgen_ty_5 = ::std::os::raw::c_uint; +pub const PF_CHANGE_NONE: _bindgen_ty_6 = 0; +pub const PF_CHANGE_ADD_HEAD: _bindgen_ty_6 = 1; +pub const PF_CHANGE_ADD_TAIL: _bindgen_ty_6 = 2; +pub const PF_CHANGE_ADD_BEFORE: _bindgen_ty_6 = 3; +pub const PF_CHANGE_ADD_AFTER: _bindgen_ty_6 = 4; +pub const PF_CHANGE_REMOVE: _bindgen_ty_6 = 5; +pub const PF_CHANGE_GET_TICKET: _bindgen_ty_6 = 6; +pub type _bindgen_ty_6 = ::std::os::raw::c_uint; +pub const PF_GET_NONE: _bindgen_ty_7 = 0; +pub const PF_GET_CLR_CNTR: _bindgen_ty_7 = 1; +pub type _bindgen_ty_7 = ::std::os::raw::c_uint; +pub const PF_SK_WIRE: _bindgen_ty_8 = 0; +pub const PF_SK_STACK: _bindgen_ty_8 = 1; +pub const PF_SK_BOTH: _bindgen_ty_8 = 2; +pub type _bindgen_ty_8 = ::std::os::raw::c_uint; +pub const PF_PEER_SRC: _bindgen_ty_9 = 0; +pub const PF_PEER_DST: _bindgen_ty_9 = 1; +pub const PF_PEER_BOTH: _bindgen_ty_9 = 2; +pub type _bindgen_ty_9 = ::std::os::raw::c_uint; +pub const PFTM_TCP_FIRST_PACKET: _bindgen_ty_10 = 0; +pub const PFTM_TCP_OPENING: _bindgen_ty_10 = 1; +pub const PFTM_TCP_ESTABLISHED: _bindgen_ty_10 = 2; +pub const PFTM_TCP_CLOSING: _bindgen_ty_10 = 3; +pub const PFTM_TCP_FIN_WAIT: _bindgen_ty_10 = 4; +pub const PFTM_TCP_CLOSED: _bindgen_ty_10 = 5; +pub const PFTM_UDP_FIRST_PACKET: _bindgen_ty_10 = 6; +pub const PFTM_UDP_SINGLE: _bindgen_ty_10 = 7; +pub const PFTM_UDP_MULTIPLE: _bindgen_ty_10 = 8; +pub const PFTM_ICMP_FIRST_PACKET: _bindgen_ty_10 = 9; +pub const PFTM_ICMP_ERROR_REPLY: _bindgen_ty_10 = 10; +pub const PFTM_OTHER_FIRST_PACKET: _bindgen_ty_10 = 11; +pub const PFTM_OTHER_SINGLE: _bindgen_ty_10 = 12; +pub const PFTM_OTHER_MULTIPLE: _bindgen_ty_10 = 13; +pub const PFTM_FRAG: _bindgen_ty_10 = 14; +pub const PFTM_INTERVAL: _bindgen_ty_10 = 15; +pub const PFTM_ADAPTIVE_START: _bindgen_ty_10 = 16; +pub const PFTM_ADAPTIVE_END: _bindgen_ty_10 = 17; +pub const PFTM_SRC_NODE: _bindgen_ty_10 = 18; +pub const PFTM_TS_DIFF: _bindgen_ty_10 = 19; +pub const PFTM_MAX: _bindgen_ty_10 = 20; +pub const PFTM_PURGE: _bindgen_ty_10 = 21; +pub const PFTM_UNLINKED: _bindgen_ty_10 = 22; +pub type _bindgen_ty_10 = ::std::os::raw::c_uint; +pub const PF_NOPFROUTE: _bindgen_ty_11 = 0; +pub const PF_FASTROUTE: _bindgen_ty_11 = 1; +pub const PF_ROUTETO: _bindgen_ty_11 = 2; +pub const PF_DUPTO: _bindgen_ty_11 = 3; +pub const PF_REPLYTO: _bindgen_ty_11 = 4; +pub type _bindgen_ty_11 = ::std::os::raw::c_uint; +pub const PF_LIMIT_STATES: _bindgen_ty_12 = 0; +pub const PF_LIMIT_SRC_NODES: _bindgen_ty_12 = 1; +pub const PF_LIMIT_FRAGS: _bindgen_ty_12 = 2; +pub const PF_LIMIT_TABLE_ENTRIES: _bindgen_ty_12 = 3; +pub const PF_LIMIT_MAX: _bindgen_ty_12 = 4; +pub type _bindgen_ty_12 = ::std::os::raw::c_uint; +pub const PF_POOL_NONE: _bindgen_ty_13 = 0; +pub const PF_POOL_BITMASK: _bindgen_ty_13 = 1; +pub const PF_POOL_RANDOM: _bindgen_ty_13 = 2; +pub const PF_POOL_SRCHASH: _bindgen_ty_13 = 3; +pub const PF_POOL_ROUNDROBIN: _bindgen_ty_13 = 4; +pub type _bindgen_ty_13 = ::std::os::raw::c_uint; +pub const PF_ADDR_ADDRMASK: _bindgen_ty_14 = 0; +pub const PF_ADDR_NOROUTE: _bindgen_ty_14 = 1; +pub const PF_ADDR_DYNIFTL: _bindgen_ty_14 = 2; +pub const PF_ADDR_TABLE: _bindgen_ty_14 = 3; +pub const PF_ADDR_URPFFAILED: _bindgen_ty_14 = 4; +pub const PF_ADDR_RANGE: _bindgen_ty_14 = 5; +pub type _bindgen_ty_14 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_nv { + pub data: *mut ::std::os::raw::c_void, + pub len: usize, + pub size: usize, +} +#[test] +fn bindgen_test_layout_pfioc_nv() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pfioc_nv)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_nv)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).data) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_nv), "::", stringify!(data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).len) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_nv), "::", stringify!(len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).size) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_nv), "::", stringify!(size)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_kif_cmp { + pub pfik_name: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_pfi_kif_cmp() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfi_kif_cmp)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfi_kif_cmp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif_cmp), + "::", + stringify!(pfik_name) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfi_kif { + pub pfik_name: [::std::os::raw::c_char; 16usize], + pub __bindgen_anon_1: pfi_kif__bindgen_ty_1, + pub pfik_packets: [[[u_int64_t; 2usize]; 2usize]; 2usize], + pub pfik_bytes: [[[u_int64_t; 2usize]; 2usize]; 2usize], + pub pfik_tzero: u_int32_t, + pub pfik_flags: u_int, + pub pfik_ifp: *mut ifnet, + pub pfik_group: *mut ifg_group, + pub pfik_rulerefs: u_int, + pub pfik_dynaddrs: pfi_kif__bindgen_ty_2, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfi_kif__bindgen_ty_1 { + pub pfik_tree: pfi_kif__bindgen_ty_1__bindgen_ty_1, + pub pfik_list: pfi_kif__bindgen_ty_1__bindgen_ty_2, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_kif__bindgen_ty_1__bindgen_ty_1 { + pub rbe_link: [*mut pfi_kif; 3usize], +} +#[test] +fn bindgen_test_layout_pfi_kif__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pfi_kif__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_kif__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_link) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rbe_link) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_kif__bindgen_ty_1__bindgen_ty_2 { + pub le_next: *mut pfi_kif, + pub le_prev: *mut *mut pfi_kif, +} +#[test] +fn bindgen_test_layout_pfi_kif__bindgen_ty_1__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfi_kif__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_kif__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).le_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(le_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).le_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(le_prev) + ) + ); +} +#[test] +fn bindgen_test_layout_pfi_kif__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pfi_kif__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_kif__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_tree) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_1), + "::", + stringify!(pfik_tree) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_list) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_1), + "::", + stringify!(pfik_list) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_kif__bindgen_ty_2 { + pub tqh_first: *mut pfi_dynaddr, + pub tqh_last: *mut *mut pfi_dynaddr, +} +#[test] +fn bindgen_test_layout_pfi_kif__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfi_kif__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_kif__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_2), + "::", + stringify!(tqh_first) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_2), + "::", + stringify!(tqh_last) + ) + ); +} +#[test] +fn bindgen_test_layout_pfi_kif() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 216usize, + concat!("Size of: ", stringify!(pfi_kif)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_packets) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_bytes) as usize - ptr as usize }, + 104usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_tzero) as usize - ptr as usize }, + 168usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_tzero)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_flags) as usize - ptr as usize }, + 172usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_ifp) as usize - ptr as usize }, + 176usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_ifp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_group) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_group)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_rulerefs) as usize - ptr as usize }, + 192usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif), + "::", + stringify!(pfik_rulerefs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_dynaddrs) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif), + "::", + stringify!(pfik_dynaddrs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_status { + pub counters: [u64; 16usize], + pub lcounters: [u64; 7usize], + pub fcounters: [u64; 3usize], + pub scounters: [u64; 3usize], + pub pcounters: [[[u64; 3usize]; 2usize]; 2usize], + pub bcounters: [[u64; 2usize]; 2usize], + pub running: u32, + pub states: u32, + pub src_nodes: u32, + pub since: u32, + pub debug: u32, + pub hostid: u32, + pub ifname: [::std::os::raw::c_char; 16usize], + pub pf_chksum: [u8; 16usize], +} +#[test] +fn bindgen_test_layout_pf_status() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 416usize, + concat!("Size of: ", stringify!(pf_status)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_status)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).counters) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(counters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lcounters) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(lcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fcounters) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(fcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scounters) as usize - ptr as usize }, + 208usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(scounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pcounters) as usize - ptr as usize }, + 232usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(pcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bcounters) as usize - ptr as usize }, + 328usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(bcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).running) as usize - ptr as usize }, + 360usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(running)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 364usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src_nodes) as usize - ptr as usize }, + 368usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(src_nodes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).since) as usize - ptr as usize }, + 372usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(since)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).debug) as usize - ptr as usize }, + 376usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(debug)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hostid) as usize - ptr as usize }, + 380usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(hostid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 384usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pf_chksum) as usize - ptr as usize }, + 400usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(pf_chksum)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_addr { + pub pfa: pf_addr__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_addr__bindgen_ty_1 { + pub v4: in_addr, + pub v6: in6_addr, + pub addr8: [u_int8_t; 16usize], + pub addr16: [u_int16_t; 8usize], + pub addr32: [u_int32_t; 4usize], +} +#[test] +fn bindgen_test_layout_pf_addr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_addr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).v4) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(v4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).v6) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(v6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(addr8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr16) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(addr16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr32) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(addr32) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_addr() { + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_addr_wrap { + pub v: pf_addr_wrap__bindgen_ty_1, + pub p: pf_addr_wrap__bindgen_ty_2, + pub type_: u_int8_t, + pub iflags: u_int8_t, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_addr_wrap__bindgen_ty_1 { + pub a: pf_addr_wrap__bindgen_ty_1__bindgen_ty_1, + pub ifname: [::std::os::raw::c_char; 16usize], + pub tblname: [::std::os::raw::c_char; 32usize], +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_addr_wrap__bindgen_ty_1__bindgen_ty_1 { + pub addr: pf_addr, + pub mask: pf_addr, +} +#[test] +fn bindgen_test_layout_pf_addr_wrap__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mask) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(mask) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_addr_wrap__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_addr_wrap__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr_wrap__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).a) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(a) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tblname) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(tblname) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_addr_wrap__bindgen_ty_2 { + pub dyn_: *mut pfi_dynaddr, + pub tbl: *mut pfr_ktable, + pub dyncnt: ::std::os::raw::c_int, + pub tblcnt: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_addr_wrap__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_addr_wrap__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_addr_wrap__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dyn_) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(dyn_) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tbl) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(tbl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dyncnt) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(dyncnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tblcnt) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(tblcnt) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_addr_wrap() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(pf_addr_wrap)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_addr_wrap)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).v) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(v)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).p) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(p)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(type_)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iflags) as usize - ptr as usize }, + 41usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(iflags)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_rule_ptr { + pub ptr: *mut pf_rule, + pub nr: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_rule_ptr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_rule_ptr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule_ptr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_ptr), "::", stringify!(ptr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_ptr), "::", stringify!(nr)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_uid { + pub uid: [uid_t; 2usize], + pub op: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_rule_uid() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(pf_rule_uid)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule_uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_uid), "::", stringify!(uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).op) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_rule_uid), "::", stringify!(op)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_gid { + pub gid: [uid_t; 2usize], + pub op: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_rule_gid() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(pf_rule_gid)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule_gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_gid), "::", stringify!(gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).op) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_rule_gid), "::", stringify!(op)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_rule_addr { + pub addr: pf_addr_wrap, + pub port: [u_int16_t; 2usize], + pub neg: u_int8_t, + pub port_op: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_rule_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(pf_rule_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).neg) as usize - ptr as usize }, + 52usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(neg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port_op) as usize - ptr as usize }, + 53usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(port_op)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_pooladdr { + pub addr: pf_addr_wrap, + pub entries: pf_pooladdr__bindgen_ty_1, + pub ifname: [::std::os::raw::c_char; 16usize], + pub kif: *mut pfi_kif, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_pooladdr__bindgen_ty_1 { + pub tqe_next: *mut pf_pooladdr, + pub tqe_prev: *mut *mut pf_pooladdr, +} +#[test] +fn bindgen_test_layout_pf_pooladdr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_pooladdr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_pooladdr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_pooladdr__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_pooladdr__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_pooladdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 88usize, + concat!("Size of: ", stringify!(pf_pooladdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_pooladdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_pooladdr), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_pooladdr), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_pooladdr), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_pooladdr), "::", stringify!(kif)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_palist { + pub tqh_first: *mut pf_pooladdr, + pub tqh_last: *mut *mut pf_pooladdr, +} +#[test] +fn bindgen_test_layout_pf_palist() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_palist)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_palist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_palist), "::", stringify!(tqh_first)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_palist), "::", stringify!(tqh_last)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_poolhashkey { + pub __bindgen_anon_1: pf_poolhashkey__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_poolhashkey__bindgen_ty_1 { + pub key8: [u_int8_t; 16usize], + pub key16: [u_int16_t; 8usize], + pub key32: [u_int32_t; 4usize], +} +#[test] +fn bindgen_test_layout_pf_poolhashkey__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_poolhashkey__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_poolhashkey__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_poolhashkey__bindgen_ty_1), + "::", + stringify!(key8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key16) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_poolhashkey__bindgen_ty_1), + "::", + stringify!(key16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key32) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_poolhashkey__bindgen_ty_1), + "::", + stringify!(key32) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_poolhashkey() { + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_poolhashkey)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_poolhashkey)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_mape_portset { + pub offset: u_int8_t, + pub psidlen: u_int8_t, + pub psid: u_int16_t, +} +#[test] +fn bindgen_test_layout_pf_mape_portset() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pf_mape_portset)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(pf_mape_portset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).offset) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_mape_portset), + "::", + stringify!(offset) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psidlen) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(pf_mape_portset), + "::", + stringify!(psidlen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psid) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(pf_mape_portset), "::", stringify!(psid)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_pool { + pub list: pf_palist, + pub cur: *mut pf_pooladdr, + pub key: pf_poolhashkey, + pub counter: pf_addr, + pub tblidx: ::std::os::raw::c_int, + pub proxy_port: [u_int16_t; 2usize], + pub opts: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_pool() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 72usize, + concat!("Size of: ", stringify!(pf_pool)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_pool)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).list) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(list)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cur) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(cur)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(key)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).counter) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(counter)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tblidx) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(tblidx)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proxy_port) as usize - ptr as usize }, + 60usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(proxy_port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).opts) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(opts)) + ); +} +pub type pf_osfp_t = u_int32_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_osfp_entry { + pub fp_entry: pf_osfp_entry__bindgen_ty_1, + pub fp_os: pf_osfp_t, + pub fp_enflags: ::std::os::raw::c_int, + pub fp_class_nm: [::std::os::raw::c_char; 32usize], + pub fp_version_nm: [::std::os::raw::c_char; 32usize], + pub fp_subtype_nm: [::std::os::raw::c_char; 32usize], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_osfp_entry__bindgen_ty_1 { + pub sle_next: *mut pf_osfp_entry, +} +#[test] +fn bindgen_test_layout_pf_osfp_entry__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_osfp_entry__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_osfp_entry__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_osfp_entry() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 112usize, + concat!("Size of: ", stringify!(pf_osfp_entry)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_osfp_entry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_entry) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_entry) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_os) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_osfp_entry), "::", stringify!(fp_os)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_enflags) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_enflags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_class_nm) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_class_nm) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_version_nm) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_version_nm) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_subtype_nm) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_subtype_nm) + ) + ); +} +pub type pf_tcpopts_t = u_int64_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_os_fingerprint { + pub fp_oses: pf_os_fingerprint_pf_osfp_enlist, + pub fp_tcpopts: pf_tcpopts_t, + pub fp_wsize: u_int16_t, + pub fp_psize: u_int16_t, + pub fp_mss: u_int16_t, + pub fp_flags: u_int16_t, + pub fp_optcnt: u_int8_t, + pub fp_wscale: u_int8_t, + pub fp_ttl: u_int8_t, + pub fp_next: pf_os_fingerprint__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_os_fingerprint_pf_osfp_enlist { + pub slh_first: *mut pf_osfp_entry, +} +#[test] +fn bindgen_test_layout_pf_os_fingerprint_pf_osfp_enlist() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_os_fingerprint_pf_osfp_enlist)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_os_fingerprint_pf_osfp_enlist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).slh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint_pf_osfp_enlist), + "::", + stringify!(slh_first) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_os_fingerprint__bindgen_ty_1 { + pub sle_next: *mut pf_os_fingerprint, +} +#[test] +fn bindgen_test_layout_pf_os_fingerprint__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_os_fingerprint__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_os_fingerprint__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_os_fingerprint() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pf_os_fingerprint)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_os_fingerprint)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_oses) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_oses) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_tcpopts) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_tcpopts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wsize) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_wsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_psize) as usize - ptr as usize }, + 18usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_psize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_mss) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_flags) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_optcnt) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_optcnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wscale) as usize - ptr as usize }, + 25usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_ttl) as usize - ptr as usize }, + 26usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_next) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_next) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_osfp_ioctl { + pub fp_os: pf_osfp_entry, + pub fp_tcpopts: pf_tcpopts_t, + pub fp_wsize: u_int16_t, + pub fp_psize: u_int16_t, + pub fp_mss: u_int16_t, + pub fp_flags: u_int16_t, + pub fp_optcnt: u_int8_t, + pub fp_wscale: u_int8_t, + pub fp_ttl: u_int8_t, + pub fp_getnum: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_osfp_ioctl() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 136usize, + concat!("Size of: ", stringify!(pf_osfp_ioctl)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_osfp_ioctl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_os) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_osfp_ioctl), "::", stringify!(fp_os)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_tcpopts) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_tcpopts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wsize) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_wsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_psize) as usize - ptr as usize }, + 122usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_psize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_mss) as usize - ptr as usize }, + 124usize, + concat!("Offset of field: ", stringify!(pf_osfp_ioctl), "::", stringify!(fp_mss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_flags) as usize - ptr as usize }, + 126usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_optcnt) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_optcnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wscale) as usize - ptr as usize }, + 129usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_ttl) as usize - ptr as usize }, + 130usize, + concat!("Offset of field: ", stringify!(pf_osfp_ioctl), "::", stringify!(fp_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_getnum) as usize - ptr as usize }, + 132usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_getnum) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_rule { + pub src: pf_rule_addr, + pub dst: pf_rule_addr, + pub skip: [pf_rule_ptr; 8usize], + pub label: [::std::os::raw::c_char; 64usize], + pub ifname: [::std::os::raw::c_char; 16usize], + pub qname: [::std::os::raw::c_char; 64usize], + pub pqname: [::std::os::raw::c_char; 64usize], + pub tagname: [::std::os::raw::c_char; 64usize], + pub match_tagname: [::std::os::raw::c_char; 64usize], + pub overload_tblname: [::std::os::raw::c_char; 32usize], + pub entries: pf_rule__bindgen_ty_1, + pub rpool: pf_pool, + pub evaluations: u_int64_t, + pub packets: [u_int64_t; 2usize], + pub bytes: [u_int64_t; 2usize], + pub kif: *mut pfi_kif, + pub anchor: *mut pf_anchor, + pub overload_tbl: *mut pfr_ktable, + pub os_fingerprint: pf_osfp_t, + pub rtableid: ::std::os::raw::c_int, + pub timeout: [u_int32_t; 20usize], + pub max_states: u_int32_t, + pub max_src_nodes: u_int32_t, + pub max_src_states: u_int32_t, + pub max_src_conn: u_int32_t, + pub max_src_conn_rate: pf_rule__bindgen_ty_2, + pub qid: u_int32_t, + pub pqid: u_int32_t, + pub rt_listid: u_int32_t, + pub nr: u_int32_t, + pub prob: u_int32_t, + pub cuid: uid_t, + pub cpid: pid_t, + pub states_cur: counter_u64_t, + pub states_tot: counter_u64_t, + pub src_nodes: counter_u64_t, + pub return_icmp: u_int16_t, + pub return_icmp6: u_int16_t, + pub max_mss: u_int16_t, + pub tag: u_int16_t, + pub match_tag: u_int16_t, + pub scrub_flags: u_int16_t, + pub uid: pf_rule_uid, + pub gid: pf_rule_gid, + pub rule_flag: u_int32_t, + pub action: u_int8_t, + pub direction: u_int8_t, + pub log: u_int8_t, + pub logif: u_int8_t, + pub quick: u_int8_t, + pub ifnot: u_int8_t, + pub match_tag_not: u_int8_t, + pub natpass: u_int8_t, + pub keep_state: u_int8_t, + pub af: sa_family_t, + pub proto: u_int8_t, + pub type_: u_int8_t, + pub code: u_int8_t, + pub flags: u_int8_t, + pub flagset: u_int8_t, + pub min_ttl: u_int8_t, + pub allow_opts: u_int8_t, + pub rt: u_int8_t, + pub return_ttl: u_int8_t, + pub tos: u_int8_t, + pub set_tos: u_int8_t, + pub anchor_relative: u_int8_t, + pub anchor_wildcard: u_int8_t, + pub flush: u_int8_t, + pub prio: u_int8_t, + pub set_prio: [u_int8_t; 2usize], + pub divert: pf_rule__bindgen_ty_3, + pub u_states_cur: u64, + pub u_states_tot: u64, + pub u_src_nodes: u64, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule__bindgen_ty_1 { + pub tqe_next: *mut pf_rule, + pub tqe_prev: *mut *mut pf_rule, +} +#[test] +fn bindgen_test_layout_pf_rule__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_rule__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule__bindgen_ty_2 { + pub limit: u_int32_t, + pub seconds: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_rule__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_rule__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_2), + "::", + stringify!(limit) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seconds) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_2), + "::", + stringify!(seconds) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_rule__bindgen_ty_3 { + pub addr: pf_addr, + pub port: u_int16_t, +} +#[test] +fn bindgen_test_layout_pf_rule__bindgen_ty_3() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pf_rule__bindgen_ty_3)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule__bindgen_ty_3)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_3), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_3), + "::", + stringify!(port) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_rule() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 976usize, + concat!("Size of: ", stringify!(pf_rule)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(src)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dst) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(dst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).skip) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(skip)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).label) as usize - ptr as usize }, + 176usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(label)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 240usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qname) as usize - ptr as usize }, + 256usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(qname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pqname) as usize - ptr as usize }, + 320usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(pqname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tagname) as usize - ptr as usize }, + 384usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(tagname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_tagname) as usize - ptr as usize }, + 448usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(match_tagname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).overload_tblname) as usize - ptr as usize }, + 512usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(overload_tblname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 544usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rpool) as usize - ptr as usize }, + 560usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rpool)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).evaluations) as usize - ptr as usize }, + 632usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(evaluations)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 640usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 656usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 672usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 680usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).overload_tbl) as usize - ptr as usize }, + 688usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(overload_tbl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).os_fingerprint) as usize - ptr as usize }, + 696usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(os_fingerprint) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtableid) as usize - ptr as usize }, + 700usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rtableid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 704usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(timeout)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_states) as usize - ptr as usize }, + 784usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(max_states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_nodes) as usize - ptr as usize }, + 788usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(max_src_nodes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_states) as usize - ptr as usize }, + 792usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(max_src_states) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_conn) as usize - ptr as usize }, + 796usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(max_src_conn)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_conn_rate) as usize - ptr as usize }, + 800usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(max_src_conn_rate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 808usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(qid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pqid) as usize - ptr as usize }, + 812usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(pqid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_listid) as usize - ptr as usize }, + 816usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rt_listid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 820usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).prob) as usize - ptr as usize }, + 824usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(prob)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cuid) as usize - ptr as usize }, + 828usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(cuid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cpid) as usize - ptr as usize }, + 832usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(cpid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states_cur) as usize - ptr as usize }, + 840usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(states_cur)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states_tot) as usize - ptr as usize }, + 848usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(states_tot)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src_nodes) as usize - ptr as usize }, + 856usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(src_nodes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).return_icmp) as usize - ptr as usize }, + 864usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(return_icmp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).return_icmp6) as usize - ptr as usize }, + 866usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(return_icmp6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_mss) as usize - ptr as usize }, + 868usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(max_mss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tag) as usize - ptr as usize }, + 870usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_tag) as usize - ptr as usize }, + 872usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(match_tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub_flags) as usize - ptr as usize }, + 874usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(scrub_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uid) as usize - ptr as usize }, + 876usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gid) as usize - ptr as usize }, + 888usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule_flag) as usize - ptr as usize }, + 900usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rule_flag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 904usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(action)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 905usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(direction)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).log) as usize - ptr as usize }, + 906usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(log)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).logif) as usize - ptr as usize }, + 907usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(logif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).quick) as usize - ptr as usize }, + 908usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(quick)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnot) as usize - ptr as usize }, + 909usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(ifnot)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_tag_not) as usize - ptr as usize }, + 910usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(match_tag_not) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).natpass) as usize - ptr as usize }, + 911usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(natpass)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).keep_state) as usize - ptr as usize }, + 912usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(keep_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 913usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 914usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(proto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 915usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(type_)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).code) as usize - ptr as usize }, + 916usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(code)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 917usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flagset) as usize - ptr as usize }, + 918usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(flagset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).min_ttl) as usize - ptr as usize }, + 919usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(min_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).allow_opts) as usize - ptr as usize }, + 920usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(allow_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt) as usize - ptr as usize }, + 921usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).return_ttl) as usize - ptr as usize }, + 922usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(return_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos) as usize - ptr as usize }, + 923usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(tos)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_tos) as usize - ptr as usize }, + 924usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(set_tos)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor_relative) as usize - ptr as usize }, + 925usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(anchor_relative) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor_wildcard) as usize - ptr as usize }, + 926usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(anchor_wildcard) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flush) as usize - ptr as usize }, + 927usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(flush)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).prio) as usize - ptr as usize }, + 928usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(prio)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_prio) as usize - ptr as usize }, + 929usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(set_prio)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).divert) as usize - ptr as usize }, + 932usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(divert)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).u_states_cur) as usize - ptr as usize }, + 952usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(u_states_cur)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).u_states_tot) as usize - ptr as usize }, + 960usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(u_states_tot)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).u_src_nodes) as usize - ptr as usize }, + 968usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(u_src_nodes)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_threshold { + pub limit: u_int32_t, + pub seconds: u_int32_t, + pub count: u_int32_t, + pub last: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_threshold() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_threshold)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_threshold)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(limit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seconds) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(seconds)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).count) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(count)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).last) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(last)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_src_node { + pub entry: pf_src_node__bindgen_ty_1, + pub addr: pf_addr, + pub raddr: pf_addr, + pub rule: pf_rule_ptr, + pub kif: *mut pfi_kif, + pub bytes: [u_int64_t; 2usize], + pub packets: [u_int64_t; 2usize], + pub states: u_int32_t, + pub conn: u_int32_t, + pub conn_rate: pf_threshold, + pub creation: u_int32_t, + pub expire: u_int32_t, + pub af: sa_family_t, + pub ruletype: u_int8_t, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_src_node__bindgen_ty_1 { + pub le_next: *mut pf_src_node, + pub le_prev: *mut *mut pf_src_node, +} +#[test] +fn bindgen_test_layout_pf_src_node__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_src_node__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_src_node__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).le_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node__bindgen_ty_1), + "::", + stringify!(le_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).le_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node__bindgen_ty_1), + "::", + stringify!(le_prev) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_src_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 136usize, + concat!("Size of: ", stringify!(pf_src_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_src_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(entry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).raddr) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(raddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).conn) as usize - ptr as usize }, + 100usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(conn)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).conn_rate) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node), + "::", + stringify!(conn_rate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creation) as usize - ptr as usize }, + 120usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(creation)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).expire) as usize - ptr as usize }, + 124usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(expire)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ruletype) as usize - ptr as usize }, + 129usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(ruletype)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rulequeue { + pub tqh_first: *mut pf_rule, + pub tqh_last: *mut *mut pf_rule, +} +#[test] +fn bindgen_test_layout_pf_rulequeue() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_rulequeue)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rulequeue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rulequeue), + "::", + stringify!(tqh_first) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_rulequeue), + "::", + stringify!(tqh_last) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ruleset { + pub rules: [pf_ruleset__bindgen_ty_1; 5usize], + pub anchor: *mut pf_anchor, + pub tticket: u_int32_t, + pub tables: ::std::os::raw::c_int, + pub topen: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ruleset__bindgen_ty_1 { + pub queues: [pf_rulequeue; 2usize], + pub active: pf_ruleset__bindgen_ty_1__bindgen_ty_1, + pub inactive: pf_ruleset__bindgen_ty_1__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ruleset__bindgen_ty_1__bindgen_ty_1 { + pub ptr: *mut pf_rulequeue, + pub ptr_array: *mut *mut pf_rule, + pub rcount: u_int32_t, + pub ticket: u_int32_t, + pub open: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_ruleset__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ptr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr_array) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ptr_array) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rcount) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rcount) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ticket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).open) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(open) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_ruleset__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(pf_ruleset__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ruleset__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).queues) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1), + "::", + stringify!(queues) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).active) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1), + "::", + stringify!(active) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).inactive) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1), + "::", + stringify!(inactive) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_ruleset() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 504usize, + concat!("Size of: ", stringify!(pf_ruleset)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rules) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(rules)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 480usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tticket) as usize - ptr as usize }, + 488usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(tticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tables) as usize - ptr as usize }, + 492usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(tables)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).topen) as usize - ptr as usize }, + 496usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(topen)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor_global { + pub rbh_root: *mut pf_anchor, +} +#[test] +fn bindgen_test_layout_pf_anchor_global() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_anchor_global)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor_global)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor_global), + "::", + stringify!(rbh_root) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor_node { + pub rbh_root: *mut pf_anchor, +} +#[test] +fn bindgen_test_layout_pf_anchor_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_anchor_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor_node), + "::", + stringify!(rbh_root) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor { + pub entry_global: pf_anchor__bindgen_ty_1, + pub entry_node: pf_anchor__bindgen_ty_2, + pub parent: *mut pf_anchor, + pub children: pf_anchor_node, + pub name: [::std::os::raw::c_char; 64usize], + pub path: [::std::os::raw::c_char; 1024usize], + pub ruleset: pf_ruleset, + pub refcnt: ::std::os::raw::c_int, + pub match_: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor__bindgen_ty_1 { + pub rbe_link: [*mut pf_anchor; 3usize], +} +#[test] +fn bindgen_test_layout_pf_anchor__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_anchor__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_link) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_1), + "::", + stringify!(rbe_link) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor__bindgen_ty_2 { + pub rbe_link: [*mut pf_anchor; 3usize], +} +#[test] +fn bindgen_test_layout_pf_anchor__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_anchor__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_link) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_2), + "::", + stringify!(rbe_link) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_anchor() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1664usize, + concat!("Size of: ", stringify!(pf_anchor)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry_global) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor), + "::", + stringify!(entry_global) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry_node) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(entry_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).children) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(children)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).path) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(path)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ruleset) as usize - ptr as usize }, + 1152usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).refcnt) as usize - ptr as usize }, + 1656usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(refcnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_) as usize - ptr as usize }, + 1660usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(match_)) + ); +} +extern "C" { + pub fn pf_anchor_global_RB_INSERT_COLOR( + arg1: *mut pf_anchor_global, + arg2: *mut pf_anchor, + arg3: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_REMOVE_COLOR( + arg1: *mut pf_anchor_global, + arg2: *mut pf_anchor, + arg3: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_INSERT_FINISH( + arg1: *mut pf_anchor_global, + arg2: *mut pf_anchor, + arg3: *mut *mut pf_anchor, + arg4: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_INSERT(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_REMOVE(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_FIND(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_NFIND(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_NEXT(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_INSERT_NEXT( + arg1: *mut pf_anchor_global, + arg2: *mut pf_anchor, + arg3: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_PREV(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_INSERT_PREV( + arg1: *mut pf_anchor_global, + arg2: *mut pf_anchor, + arg3: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_MINMAX(arg1: *mut pf_anchor_global, arg2: ::std::os::raw::c_int) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_REINSERT(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_INSERT_COLOR( + arg1: *mut pf_anchor_node, + arg2: *mut pf_anchor, + arg3: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_REMOVE_COLOR( + arg1: *mut pf_anchor_node, + arg2: *mut pf_anchor, + arg3: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_INSERT_FINISH( + arg1: *mut pf_anchor_node, + arg2: *mut pf_anchor, + arg3: *mut *mut pf_anchor, + arg4: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_INSERT(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_REMOVE(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_FIND(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_NFIND(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_NEXT(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_INSERT_NEXT( + arg1: *mut pf_anchor_node, + arg2: *mut pf_anchor, + arg3: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_PREV(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_INSERT_PREV( + arg1: *mut pf_anchor_node, + arg2: *mut pf_anchor, + arg3: *mut pf_anchor, + ) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_MINMAX(arg1: *mut pf_anchor_node, arg2: ::std::os::raw::c_int) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_REINSERT(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_get_ruleset_number(arg1: u_int8_t) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct cbq_opts { + pub minburst: u_int, + pub maxburst: u_int, + pub pktsize: u_int, + pub maxpktsize: u_int, + pub ns_per_byte: u_int, + pub maxidle: u_int, + pub minidle: ::std::os::raw::c_int, + pub offtime: u_int, + pub flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_cbq_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 36usize, + concat!("Size of: ", stringify!(cbq_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(cbq_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).minburst) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(minburst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).maxburst) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(maxburst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pktsize) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(pktsize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).maxpktsize) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(maxpktsize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ns_per_byte) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(ns_per_byte)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).maxidle) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(maxidle)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).minidle) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(minidle)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).offtime) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(offtime)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct codel_opts { + pub target: u_int, + pub interval: u_int, + pub ecn: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_codel_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(codel_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(codel_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).target) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(codel_opts), "::", stringify!(target)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).interval) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(codel_opts), "::", stringify!(interval)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(codel_opts), "::", stringify!(ecn)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct priq_opts { + pub flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_priq_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(priq_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(priq_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(priq_opts), "::", stringify!(flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct hfsc_opts_v0 { + pub rtsc_m1: u_int, + pub rtsc_d: u_int, + pub rtsc_m2: u_int, + pub lssc_m1: u_int, + pub lssc_d: u_int, + pub lssc_m2: u_int, + pub ulsc_m1: u_int, + pub ulsc_d: u_int, + pub ulsc_m2: u_int, + pub flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_hfsc_opts_v0() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(hfsc_opts_v0)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(hfsc_opts_v0)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_m1) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(rtsc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_d) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(rtsc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_m2) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(rtsc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m1) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(lssc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_d) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(lssc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m2) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(lssc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_m1) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(ulsc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_d) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(ulsc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_m2) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(ulsc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 36usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v0), "::", stringify!(flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct hfsc_opts_v1 { + pub rtsc_m1: u_int64_t, + pub rtsc_d: u_int, + pub rtsc_m2: u_int64_t, + pub lssc_m1: u_int64_t, + pub lssc_d: u_int, + pub lssc_m2: u_int64_t, + pub ulsc_m1: u_int64_t, + pub ulsc_d: u_int, + pub ulsc_m2: u_int64_t, + pub flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_hfsc_opts_v1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 80usize, + concat!("Size of: ", stringify!(hfsc_opts_v1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(hfsc_opts_v1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_m1) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(rtsc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_d) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(rtsc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_m2) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(rtsc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m1) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(lssc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_d) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(lssc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m2) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(lssc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_m1) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(ulsc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_d) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(ulsc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_m2) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(ulsc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(hfsc_opts_v1), "::", stringify!(flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct fairq_opts { + pub nbuckets: u_int, + pub hogs_m1: u_int, + pub flags: ::std::os::raw::c_int, + pub lssc_m1: u_int, + pub lssc_d: u_int, + pub lssc_m2: u_int, +} +#[test] +fn bindgen_test_layout_fairq_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(fairq_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(fairq_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nbuckets) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(nbuckets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hogs_m1) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(hogs_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m1) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(lssc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_d) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(lssc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m2) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(lssc_m2)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_altq_v0 { + pub ifname: [::std::os::raw::c_char; 16usize], + pub unused1: *mut ::std::os::raw::c_void, + pub entries: pf_altq_v0__bindgen_ty_1, + pub scheduler: u8, + pub tbrsize: u16, + pub ifbandwidth: u32, + pub qname: [::std::os::raw::c_char; 64usize], + pub parent: [::std::os::raw::c_char; 64usize], + pub parent_qid: u32, + pub bandwidth: u32, + pub priority: u8, + pub local_flags: u8, + pub qlimit: u16, + pub flags: u16, + pub pq_u: pf_altq_v0__bindgen_ty_2, + pub qid: u32, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_altq_v0__bindgen_ty_1 { + pub tqe_next: *mut pf_altq_v0, + pub tqe_prev: *mut *mut pf_altq_v0, +} +#[test] +fn bindgen_test_layout_pf_altq_v0__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_altq_v0__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_altq_v0__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_altq_v0__bindgen_ty_2 { + pub cbq_opts: cbq_opts, + pub codel_opts: codel_opts, + pub priq_opts: priq_opts, + pub hfsc_opts: hfsc_opts_v0, + pub fairq_opts: fairq_opts, +} +#[test] +fn bindgen_test_layout_pf_altq_v0__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pf_altq_v0__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_altq_v0__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cbq_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0__bindgen_ty_2), + "::", + stringify!(cbq_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).codel_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0__bindgen_ty_2), + "::", + stringify!(codel_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).priq_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0__bindgen_ty_2), + "::", + stringify!(priq_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hfsc_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0__bindgen_ty_2), + "::", + stringify!(hfsc_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fairq_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0__bindgen_ty_2), + "::", + stringify!(fairq_opts) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_altq_v0() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 240usize, + concat!("Size of: ", stringify!(pf_altq_v0)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_altq_v0)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).unused1) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(unused1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scheduler) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(scheduler)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tbrsize) as usize - ptr as usize }, + 42usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(tbrsize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifbandwidth) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0), + "::", + stringify!(ifbandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qname) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(qname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent_qid) as usize - ptr as usize }, + 176usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0), + "::", + stringify!(parent_qid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bandwidth) as usize - ptr as usize }, + 180usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(bandwidth)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).priority) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(priority)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).local_flags) as usize - ptr as usize }, + 185usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v0), + "::", + stringify!(local_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qlimit) as usize - ptr as usize }, + 186usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(qlimit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 188usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pq_u) as usize - ptr as usize }, + 192usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(pq_u)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 232usize, + concat!("Offset of field: ", stringify!(pf_altq_v0), "::", stringify!(qid)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_altq_v1 { + pub ifname: [::std::os::raw::c_char; 16usize], + pub entries: pf_altq_v1__bindgen_ty_1, + pub scheduler: u8, + pub tbrsize: u32, + pub ifbandwidth: u64, + pub qname: [::std::os::raw::c_char; 64usize], + pub parent: [::std::os::raw::c_char; 64usize], + pub parent_qid: u32, + pub bandwidth: u64, + pub priority: u8, + pub local_flags: u8, + pub qlimit: u16, + pub flags: u16, + pub pq_u: pf_altq_v1__bindgen_ty_2, + pub qid: u32, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_altq_v1__bindgen_ty_1 { + pub tqe_next: *mut pf_altq_v1, + pub tqe_prev: *mut *mut pf_altq_v1, +} +#[test] +fn bindgen_test_layout_pf_altq_v1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_altq_v1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_altq_v1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_altq_v1__bindgen_ty_2 { + pub cbq_opts: cbq_opts, + pub codel_opts: codel_opts, + pub priq_opts: priq_opts, + pub hfsc_opts: hfsc_opts_v1, + pub fairq_opts: fairq_opts, +} +#[test] +fn bindgen_test_layout_pf_altq_v1__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 80usize, + concat!("Size of: ", stringify!(pf_altq_v1__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_altq_v1__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cbq_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1__bindgen_ty_2), + "::", + stringify!(cbq_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).codel_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1__bindgen_ty_2), + "::", + stringify!(codel_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).priq_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1__bindgen_ty_2), + "::", + stringify!(priq_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hfsc_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1__bindgen_ty_2), + "::", + stringify!(hfsc_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fairq_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1__bindgen_ty_2), + "::", + stringify!(fairq_opts) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_altq_v1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 288usize, + concat!("Size of: ", stringify!(pf_altq_v1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_altq_v1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scheduler) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(scheduler)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tbrsize) as usize - ptr as usize }, + 36usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(tbrsize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifbandwidth) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1), + "::", + stringify!(ifbandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qname) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(qname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent_qid) as usize - ptr as usize }, + 176usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1), + "::", + stringify!(parent_qid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bandwidth) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(bandwidth)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).priority) as usize - ptr as usize }, + 192usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(priority)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).local_flags) as usize - ptr as usize }, + 193usize, + concat!( + "Offset of field: ", + stringify!(pf_altq_v1), + "::", + stringify!(local_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qlimit) as usize - ptr as usize }, + 194usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(qlimit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 196usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pq_u) as usize - ptr as usize }, + 200usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(pq_u)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 280usize, + concat!("Offset of field: ", stringify!(pf_altq_v1), "::", stringify!(qid)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_scrub { + pub pfss_last: timeval, + pub pfss_tsecr: u_int32_t, + pub pfss_tsval: u_int32_t, + pub pfss_tsval0: u_int32_t, + pub pfss_flags: u_int16_t, + pub pfss_ttl: u_int8_t, + pub pad: u_int8_t, + pub pfss_ts_mod: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_state_scrub() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pf_state_scrub)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_scrub)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_last) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_last) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_tsecr) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_tsecr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_tsval) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_tsval) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_tsval0) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_tsval0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_flags) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ttl) as usize - ptr as usize }, + 30usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 31usize, + concat!("Offset of field: ", stringify!(pf_state_scrub), "::", stringify!(pad)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ts_mod) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_ts_mod) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_state_host { + pub addr: pf_addr, + pub port: u_int16_t, + pub pad: u_int16_t, +} +#[test] +fn bindgen_test_layout_pf_state_host() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pf_state_host)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_state_host)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_host), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_state_host), "::", stringify!(port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(pf_state_host), "::", stringify!(pad)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_peer { + pub scrub: *mut pf_state_scrub, + pub seqlo: u_int32_t, + pub seqhi: u_int32_t, + pub seqdiff: u_int32_t, + pub max_win: u_int16_t, + pub mss: u_int16_t, + pub state: u_int8_t, + pub wscale: u_int8_t, + pub tcp_est: u_int8_t, + pub pad: [u_int8_t; 1usize], +} +#[test] +fn bindgen_test_layout_pf_state_peer() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_state_peer)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_peer)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(scrub)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqlo) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(seqlo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqhi) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(seqhi)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqdiff) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer), + "::", + stringify!(seqdiff) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_win) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer), + "::", + stringify!(max_win) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mss) as usize - ptr as usize }, + 22usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(mss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).wscale) as usize - ptr as usize }, + 25usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(wscale)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tcp_est) as usize - ptr as usize }, + 26usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer), + "::", + stringify!(tcp_est) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 27usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(pad)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_state_key_cmp { + pub addr: [pf_addr; 2usize], + pub port: [u_int16_t; 2usize], + pub af: sa_family_t, + pub proto: u_int8_t, + pub pad: [u_int8_t; 2usize], +} +#[test] +fn bindgen_test_layout_pf_state_key_cmp() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pf_state_key_cmp)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_state_key_cmp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_cmp), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_cmp), + "::", + stringify!(port) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 36usize, + concat!("Offset of field: ", stringify!(pf_state_key_cmp), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 37usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_cmp), + "::", + stringify!(proto) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 38usize, + concat!("Offset of field: ", stringify!(pf_state_key_cmp), "::", stringify!(pad)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_state_key { + pub addr: [pf_addr; 2usize], + pub port: [u_int16_t; 2usize], + pub af: sa_family_t, + pub proto: u_int8_t, + pub pad: [u_int8_t; 2usize], + pub entry: pf_state_key__bindgen_ty_1, + pub states: [pf_state_key__bindgen_ty_2; 2usize], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_key__bindgen_ty_1 { + pub le_next: *mut pf_state_key, + pub le_prev: *mut *mut pf_state_key, +} +#[test] +fn bindgen_test_layout_pf_state_key__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_state_key__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_key__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).le_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key__bindgen_ty_1), + "::", + stringify!(le_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).le_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key__bindgen_ty_1), + "::", + stringify!(le_prev) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_key__bindgen_ty_2 { + pub tqh_first: *mut pf_kstate, + pub tqh_last: *mut *mut pf_kstate, +} +#[test] +fn bindgen_test_layout_pf_state_key__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_state_key__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_key__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key__bindgen_ty_2), + "::", + stringify!(tqh_first) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key__bindgen_ty_2), + "::", + stringify!(tqh_last) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_state_key() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 88usize, + concat!("Size of: ", stringify!(pf_state_key)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_key)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_key), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pf_state_key), "::", stringify!(port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 36usize, + concat!("Offset of field: ", stringify!(pf_state_key), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 37usize, + concat!("Offset of field: ", stringify!(pf_state_key), "::", stringify!(proto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 38usize, + concat!("Offset of field: ", stringify!(pf_state_key), "::", stringify!(pad)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_state_key), "::", stringify!(entry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_state_key), "::", stringify!(states)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_cmp { + pub id: u_int64_t, + pub creatorid: u_int32_t, + pub direction: u_int8_t, + pub pad: [u_int8_t; 3usize], +} +#[test] +fn bindgen_test_layout_pf_state_cmp() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_state_cmp)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_cmp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).id) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_cmp), "::", stringify!(id)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creatorid) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_state_cmp), + "::", + stringify!(creatorid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pf_state_cmp), + "::", + stringify!(direction) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 13usize, + concat!("Offset of field: ", stringify!(pf_state_cmp), "::", stringify!(pad)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_scrub_export { + pub pfss_flags: u16, + pub pfss_ttl: u8, + pub scrub_flag: u8, + pub pfss_ts_mod: u32, +} +#[test] +fn bindgen_test_layout_pf_state_scrub_export() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_state_scrub_export)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_state_scrub_export)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_flags) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub_export), + "::", + stringify!(pfss_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ttl) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub_export), + "::", + stringify!(pfss_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub_flag) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub_export), + "::", + stringify!(scrub_flag) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ts_mod) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub_export), + "::", + stringify!(pfss_ts_mod) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_state_key_export { + pub addr: [pf_addr; 2usize], + pub port: [u16; 2usize], +} +#[test] +fn bindgen_test_layout_pf_state_key_export() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 36usize, + concat!("Size of: ", stringify!(pf_state_key_export)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_state_key_export)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_export), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_export), + "::", + stringify!(port) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_peer_export { + pub scrub: pf_state_scrub_export, + pub seqlo: u32, + pub seqhi: u32, + pub seqdiff: u32, + pub max_win: u16, + pub mss: u16, + pub state: u8, + pub wscale: u8, + pub dummy: [u8; 6usize], +} +#[test] +fn bindgen_test_layout_pf_state_peer_export() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_state_peer_export)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_state_peer_export)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer_export), + "::", + stringify!(scrub) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqlo) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer_export), + "::", + stringify!(seqlo) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqhi) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer_export), + "::", + stringify!(seqhi) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqdiff) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer_export), + "::", + stringify!(seqdiff) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_win) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer_export), + "::", + stringify!(max_win) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mss) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer_export), + "::", + stringify!(mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer_export), + "::", + stringify!(state) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).wscale) as usize - ptr as usize }, + 25usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer_export), + "::", + stringify!(wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dummy) as usize - ptr as usize }, + 26usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer_export), + "::", + stringify!(dummy) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_state_export { + pub version: u64, + pub id: u64, + pub ifname: [::std::os::raw::c_char; 16usize], + pub orig_ifname: [::std::os::raw::c_char; 16usize], + pub key: [pf_state_key_export; 2usize], + pub src: pf_state_peer_export, + pub dst: pf_state_peer_export, + pub rt_addr: pf_addr, + pub rule: u32, + pub anchor: u32, + pub nat_rule: u32, + pub creation: u32, + pub expire: u32, + pub spare0: u32, + pub packets: [u64; 2usize], + pub bytes: [u64; 2usize], + pub creatorid: u32, + pub spare1: u32, + pub af: sa_family_t, + pub proto: u8, + pub direction: u8, + pub log: u8, + pub state_flags_compat: u8, + pub timeout: u8, + pub sync_flags: u8, + pub updates: u8, + pub state_flags: u16, + pub qid: u16, + pub pqid: u16, + pub dnpipe: u16, + pub dnrpipe: u16, + pub rtableid: i32, + pub min_ttl: u8, + pub set_tos: u8, + pub max_mss: u16, + pub set_prio: [u8; 2usize], + pub rt: u8, + pub rt_ifname: [::std::os::raw::c_char; 16usize], + pub spare: [u8; 72usize], +} +#[test] +fn bindgen_test_layout_pf_state_export() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 384usize, + concat!("Size of: ", stringify!(pf_state_export)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_export)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).id) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(id)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).orig_ifname) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(orig_ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(key)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src) as usize - ptr as usize }, + 120usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(src)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dst) as usize - ptr as usize }, + 152usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(dst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_addr) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(rt_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 200usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 204usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nat_rule) as usize - ptr as usize }, + 208usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(nat_rule) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creation) as usize - ptr as usize }, + 212usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(creation) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).expire) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(expire) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).spare0) as usize - ptr as usize }, + 220usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(spare0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 224usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 240usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creatorid) as usize - ptr as usize }, + 256usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(creatorid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).spare1) as usize - ptr as usize }, + 260usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(spare1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 264usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 265usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(proto) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 266usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(direction) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).log) as usize - ptr as usize }, + 267usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(log)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state_flags_compat) as usize - ptr as usize }, + 268usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(state_flags_compat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 269usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(timeout) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sync_flags) as usize - ptr as usize }, + 270usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(sync_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).updates) as usize - ptr as usize }, + 271usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(updates) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state_flags) as usize - ptr as usize }, + 272usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(state_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 274usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(qid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pqid) as usize - ptr as usize }, + 276usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(pqid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dnpipe) as usize - ptr as usize }, + 278usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(dnpipe) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dnrpipe) as usize - ptr as usize }, + 280usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(dnrpipe) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtableid) as usize - ptr as usize }, + 284usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(rtableid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).min_ttl) as usize - ptr as usize }, + 288usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(min_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_tos) as usize - ptr as usize }, + 289usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(set_tos) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_mss) as usize - ptr as usize }, + 290usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(max_mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_prio) as usize - ptr as usize }, + 292usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(set_prio) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt) as usize - ptr as usize }, + 294usize, + concat!("Offset of field: ", stringify!(pf_state_export), "::", stringify!(rt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_ifname) as usize - ptr as usize }, + 295usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(rt_ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).spare) as usize - ptr as usize }, + 311usize, + concat!( + "Offset of field: ", + stringify!(pf_state_export), + "::", + stringify!(spare) + ) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct pfsync_state_scrub { + pub pfss_flags: u_int16_t, + pub pfss_ttl: u_int8_t, + pub scrub_flag: u_int8_t, + pub pfss_ts_mod: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfsync_state_scrub() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfsync_state_scrub)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_scrub)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_flags) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(pfss_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ttl) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(pfss_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub_flag) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(scrub_flag) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ts_mod) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(pfss_ts_mod) + ) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct pfsync_state_peer { + pub scrub: pfsync_state_scrub, + pub seqlo: u_int32_t, + pub seqhi: u_int32_t, + pub seqdiff: u_int32_t, + pub max_win: u_int16_t, + pub mss: u_int16_t, + pub state: u_int8_t, + pub wscale: u_int8_t, + pub pad: [u_int8_t; 6usize], +} +#[test] +fn bindgen_test_layout_pfsync_state_peer() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pfsync_state_peer)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_peer)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(scrub) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqlo) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(seqlo) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqhi) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(seqhi) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqdiff) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(seqdiff) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_win) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(max_win) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mss) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(state) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).wscale) as usize - ptr as usize }, + 25usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 26usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(pad) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfsync_state_key { + pub addr: [pf_addr; 2usize], + pub port: [u_int16_t; 2usize], +} +#[test] +fn bindgen_test_layout_pfsync_state_key() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 36usize, + concat!("Size of: ", stringify!(pfsync_state_key)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfsync_state_key)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_key), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_key), + "::", + stringify!(port) + ) + ); +} +#[repr(C, packed)] +#[derive(Copy, Clone)] +pub struct pfsync_state_1301 { + pub id: u_int64_t, + pub ifname: [::std::os::raw::c_char; 16usize], + pub key: [pfsync_state_key; 2usize], + pub src: pfsync_state_peer, + pub dst: pfsync_state_peer, + pub rt_addr: pf_addr, + pub rule: u_int32_t, + pub anchor: u_int32_t, + pub nat_rule: u_int32_t, + pub creation: u_int32_t, + pub expire: u_int32_t, + pub packets: [[u_int32_t; 2usize]; 2usize], + pub bytes: [[u_int32_t; 2usize]; 2usize], + pub creatorid: u_int32_t, + pub af: sa_family_t, + pub proto: u_int8_t, + pub direction: u_int8_t, + pub __spare: [u_int8_t; 2usize], + pub log: u_int8_t, + pub state_flags: u_int8_t, + pub timeout: u_int8_t, + pub sync_flags: u_int8_t, + pub updates: u_int8_t, +} +#[test] +fn bindgen_test_layout_pfsync_state_1301() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 242usize, + concat!("Size of: ", stringify!(pfsync_state_1301)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_1301)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).id) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfsync_state_1301), "::", stringify!(id)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(key) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(src) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dst) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(dst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_addr) as usize - ptr as usize }, + 160usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(rt_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 176usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(rule) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 180usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nat_rule) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(nat_rule) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creation) as usize - ptr as usize }, + 188usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(creation) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).expire) as usize - ptr as usize }, + 192usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(expire) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 196usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 212usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creatorid) as usize - ptr as usize }, + 228usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(creatorid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 232usize, + concat!("Offset of field: ", stringify!(pfsync_state_1301), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 233usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(proto) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 234usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(direction) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__spare) as usize - ptr as usize }, + 235usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(__spare) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).log) as usize - ptr as usize }, + 237usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(log) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state_flags) as usize - ptr as usize }, + 238usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(state_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 239usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(timeout) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sync_flags) as usize - ptr as usize }, + 240usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(sync_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).updates) as usize - ptr as usize }, + 241usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1301), + "::", + stringify!(updates) + ) + ); +} +#[repr(C, packed)] +#[derive(Copy, Clone)] +pub struct pfsync_state_1400 { + pub id: u_int64_t, + pub ifname: [::std::os::raw::c_char; 16usize], + pub key: [pfsync_state_key; 2usize], + pub src: pfsync_state_peer, + pub dst: pfsync_state_peer, + pub rt_addr: pf_addr, + pub rule: u_int32_t, + pub anchor: u_int32_t, + pub nat_rule: u_int32_t, + pub creation: u_int32_t, + pub expire: u_int32_t, + pub packets: [[u_int32_t; 2usize]; 2usize], + pub bytes: [[u_int32_t; 2usize]; 2usize], + pub creatorid: u_int32_t, + pub af: sa_family_t, + pub proto: u_int8_t, + pub direction: u_int8_t, + pub state_flags: u_int16_t, + pub log: u_int8_t, + pub __spare: u_int8_t, + pub timeout: u_int8_t, + pub sync_flags: u_int8_t, + pub updates: u_int8_t, + pub qid: u_int16_t, + pub pqid: u_int16_t, + pub dnpipe: u_int16_t, + pub dnrpipe: u_int16_t, + pub rtableid: i32, + pub min_ttl: u_int8_t, + pub set_tos: u_int8_t, + pub max_mss: u_int16_t, + pub set_prio: [u_int8_t; 2usize], + pub rt: u_int8_t, + pub rt_ifname: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_pfsync_state_1400() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 277usize, + concat!("Size of: ", stringify!(pfsync_state_1400)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_1400)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).id) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfsync_state_1400), "::", stringify!(id)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(key) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(src) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dst) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(dst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_addr) as usize - ptr as usize }, + 160usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(rt_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 176usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(rule) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 180usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nat_rule) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(nat_rule) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creation) as usize - ptr as usize }, + 188usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(creation) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).expire) as usize - ptr as usize }, + 192usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(expire) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 196usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 212usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creatorid) as usize - ptr as usize }, + 228usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(creatorid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 232usize, + concat!("Offset of field: ", stringify!(pfsync_state_1400), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 233usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(proto) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 234usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(direction) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state_flags) as usize - ptr as usize }, + 235usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(state_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).log) as usize - ptr as usize }, + 237usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(log) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__spare) as usize - ptr as usize }, + 238usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(__spare) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 239usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(timeout) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sync_flags) as usize - ptr as usize }, + 240usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(sync_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).updates) as usize - ptr as usize }, + 241usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(updates) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 242usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(qid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pqid) as usize - ptr as usize }, + 244usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(pqid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dnpipe) as usize - ptr as usize }, + 246usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(dnpipe) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dnrpipe) as usize - ptr as usize }, + 248usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(dnrpipe) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtableid) as usize - ptr as usize }, + 250usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(rtableid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).min_ttl) as usize - ptr as usize }, + 254usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(min_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_tos) as usize - ptr as usize }, + 255usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(set_tos) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_mss) as usize - ptr as usize }, + 256usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(max_mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_prio) as usize - ptr as usize }, + 258usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(set_prio) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt) as usize - ptr as usize }, + 260usize, + concat!("Offset of field: ", stringify!(pfsync_state_1400), "::", stringify!(rt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_ifname) as usize - ptr as usize }, + 261usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_1400), + "::", + stringify!(rt_ifname) + ) + ); +} +#[repr(C, packed)] +#[derive(Copy, Clone)] +pub union pfsync_state_union { + pub pfs_1301: pfsync_state_1301, + pub pfs_1400: pfsync_state_1400, +} +#[test] +fn bindgen_test_layout_pfsync_state_union() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 277usize, + concat!("Size of: ", stringify!(pfsync_state_union)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_union)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfs_1301) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_union), + "::", + stringify!(pfs_1301) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfs_1400) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_union), + "::", + stringify!(pfs_1400) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_krulequeue { + pub tqh_first: *mut pf_krule, + pub tqh_last: *mut *mut pf_krule, +} +#[test] +fn bindgen_test_layout_pf_krulequeue() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_krulequeue)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_krulequeue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_krulequeue), + "::", + stringify!(tqh_first) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_krulequeue), + "::", + stringify!(tqh_last) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kruleset { + pub rules: [pf_kruleset__bindgen_ty_1; 5usize], + pub anchor: *mut pf_kanchor, + pub tticket: u_int32_t, + pub tables: ::std::os::raw::c_int, + pub topen: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kruleset__bindgen_ty_1 { + pub queues: [pf_krulequeue; 2usize], + pub active: pf_kruleset__bindgen_ty_1__bindgen_ty_1, + pub inactive: pf_kruleset__bindgen_ty_1__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kruleset__bindgen_ty_1__bindgen_ty_1 { + pub ptr: *mut pf_krulequeue, + pub ptr_array: *mut *mut pf_krule, + pub rcount: u_int32_t, + pub ticket: u_int32_t, + pub open: ::std::os::raw::c_int, + pub tree: *mut pf_krule_global, +} +#[test] +fn bindgen_test_layout_pf_kruleset__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pf_kruleset__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_kruleset__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_kruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ptr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr_array) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_kruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ptr_array) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rcount) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_kruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rcount) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_kruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ticket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).open) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_kruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(open) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tree) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_kruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(tree) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_kruleset__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 112usize, + concat!("Size of: ", stringify!(pf_kruleset__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_kruleset__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).queues) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_kruleset__bindgen_ty_1), + "::", + stringify!(queues) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).active) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_kruleset__bindgen_ty_1), + "::", + stringify!(active) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).inactive) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(pf_kruleset__bindgen_ty_1), + "::", + stringify!(inactive) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_kruleset() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 584usize, + concat!("Size of: ", stringify!(pf_kruleset)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_kruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rules) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_kruleset), "::", stringify!(rules)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 560usize, + concat!("Offset of field: ", stringify!(pf_kruleset), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tticket) as usize - ptr as usize }, + 568usize, + concat!("Offset of field: ", stringify!(pf_kruleset), "::", stringify!(tticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tables) as usize - ptr as usize }, + 572usize, + concat!("Offset of field: ", stringify!(pf_kruleset), "::", stringify!(tables)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).topen) as usize - ptr as usize }, + 576usize, + concat!("Offset of field: ", stringify!(pf_kruleset), "::", stringify!(topen)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kanchor_global { + pub rbh_root: *mut pf_kanchor, +} +#[test] +fn bindgen_test_layout_pf_kanchor_global() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_kanchor_global)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_kanchor_global)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_kanchor_global), + "::", + stringify!(rbh_root) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kanchor_node { + pub rbh_root: *mut pf_kanchor, +} +#[test] +fn bindgen_test_layout_pf_kanchor_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_kanchor_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_kanchor_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_kanchor_node), + "::", + stringify!(rbh_root) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kanchor { + pub entry_global: pf_kanchor__bindgen_ty_1, + pub entry_node: pf_kanchor__bindgen_ty_2, + pub parent: *mut pf_kanchor, + pub children: pf_kanchor_node, + pub name: [::std::os::raw::c_char; 64usize], + pub path: [::std::os::raw::c_char; 1024usize], + pub ruleset: pf_kruleset, + pub refcnt: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kanchor__bindgen_ty_1 { + pub rbe_link: [*mut pf_kanchor; 3usize], +} +#[test] +fn bindgen_test_layout_pf_kanchor__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_kanchor__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_kanchor__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_link) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_kanchor__bindgen_ty_1), + "::", + stringify!(rbe_link) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kanchor__bindgen_ty_2 { + pub rbe_link: [*mut pf_kanchor; 3usize], +} +#[test] +fn bindgen_test_layout_pf_kanchor__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_kanchor__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_kanchor__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_link) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_kanchor__bindgen_ty_2), + "::", + stringify!(rbe_link) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_kanchor() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1744usize, + concat!("Size of: ", stringify!(pf_kanchor)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_kanchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry_global) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_kanchor), + "::", + stringify!(entry_global) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry_node) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_kanchor), + "::", + stringify!(entry_node) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_kanchor), "::", stringify!(parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).children) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_kanchor), "::", stringify!(children)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_kanchor), "::", stringify!(name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).path) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(pf_kanchor), "::", stringify!(path)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ruleset) as usize - ptr as usize }, + 1152usize, + concat!("Offset of field: ", stringify!(pf_kanchor), "::", stringify!(ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).refcnt) as usize - ptr as usize }, + 1736usize, + concat!("Offset of field: ", stringify!(pf_kanchor), "::", stringify!(refcnt)) + ); +} +extern "C" { + pub fn pf_kanchor_global_RB_INSERT_COLOR( + arg1: *mut pf_kanchor_global, + arg2: *mut pf_kanchor, + arg3: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_REMOVE_COLOR( + arg1: *mut pf_kanchor_global, + arg2: *mut pf_kanchor, + arg3: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_INSERT_FINISH( + arg1: *mut pf_kanchor_global, + arg2: *mut pf_kanchor, + arg3: *mut *mut pf_kanchor, + arg4: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_INSERT(arg1: *mut pf_kanchor_global, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_REMOVE(arg1: *mut pf_kanchor_global, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_FIND(arg1: *mut pf_kanchor_global, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_NFIND(arg1: *mut pf_kanchor_global, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_NEXT(arg1: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_INSERT_NEXT( + arg1: *mut pf_kanchor_global, + arg2: *mut pf_kanchor, + arg3: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_PREV(arg1: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_INSERT_PREV( + arg1: *mut pf_kanchor_global, + arg2: *mut pf_kanchor, + arg3: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_MINMAX(arg1: *mut pf_kanchor_global, arg2: ::std::os::raw::c_int) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_global_RB_REINSERT(arg1: *mut pf_kanchor_global, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_INSERT_COLOR( + arg1: *mut pf_kanchor_node, + arg2: *mut pf_kanchor, + arg3: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_REMOVE_COLOR( + arg1: *mut pf_kanchor_node, + arg2: *mut pf_kanchor, + arg3: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_INSERT_FINISH( + arg1: *mut pf_kanchor_node, + arg2: *mut pf_kanchor, + arg3: *mut *mut pf_kanchor, + arg4: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_INSERT(arg1: *mut pf_kanchor_node, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_REMOVE(arg1: *mut pf_kanchor_node, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_FIND(arg1: *mut pf_kanchor_node, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_NFIND(arg1: *mut pf_kanchor_node, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_NEXT(arg1: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_INSERT_NEXT( + arg1: *mut pf_kanchor_node, + arg2: *mut pf_kanchor, + arg3: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_PREV(arg1: *mut pf_kanchor) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_INSERT_PREV( + arg1: *mut pf_kanchor_node, + arg2: *mut pf_kanchor, + arg3: *mut pf_kanchor, + ) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_MINMAX(arg1: *mut pf_kanchor_node, arg2: ::std::os::raw::c_int) -> *mut pf_kanchor; +} +extern "C" { + pub fn pf_kanchor_node_RB_REINSERT(arg1: *mut pf_kanchor_node, arg2: *mut pf_kanchor) -> *mut pf_kanchor; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kanchor_stackframe { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_keth_anchor_stackframe { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_table { + pub pfrt_anchor: [::std::os::raw::c_char; 1024usize], + pub pfrt_name: [::std::os::raw::c_char; 32usize], + pub pfrt_flags: u_int32_t, + pub pfrt_fback: u_int8_t, +} +#[test] +fn bindgen_test_layout_pfr_table() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1064usize, + concat!("Size of: ", stringify!(pfr_table)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfr_table)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_anchor) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_table), + "::", + stringify!(pfrt_anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_name) as usize - ptr as usize }, + 1024usize, + concat!("Offset of field: ", stringify!(pfr_table), "::", stringify!(pfrt_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_flags) as usize - ptr as usize }, + 1056usize, + concat!("Offset of field: ", stringify!(pfr_table), "::", stringify!(pfrt_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_fback) as usize - ptr as usize }, + 1060usize, + concat!("Offset of field: ", stringify!(pfr_table), "::", stringify!(pfrt_fback)) + ); +} +pub const PFR_FB_NONE: _bindgen_ty_15 = 0; +pub const PFR_FB_MATCH: _bindgen_ty_15 = 1; +pub const PFR_FB_ADDED: _bindgen_ty_15 = 2; +pub const PFR_FB_DELETED: _bindgen_ty_15 = 3; +pub const PFR_FB_CHANGED: _bindgen_ty_15 = 4; +pub const PFR_FB_CLEARED: _bindgen_ty_15 = 5; +pub const PFR_FB_DUPLICATE: _bindgen_ty_15 = 6; +pub const PFR_FB_NOTMATCH: _bindgen_ty_15 = 7; +pub const PFR_FB_CONFLICT: _bindgen_ty_15 = 8; +pub const PFR_FB_NOCOUNT: _bindgen_ty_15 = 9; +pub const PFR_FB_MAX: _bindgen_ty_15 = 10; +pub type _bindgen_ty_15 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_addr { + pub pfra_u: pfr_addr__bindgen_ty_1, + pub pfra_af: u_int8_t, + pub pfra_net: u_int8_t, + pub pfra_not: u_int8_t, + pub pfra_fback: u_int8_t, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfr_addr__bindgen_ty_1 { + pub _pfra_ip4addr: in_addr, + pub _pfra_ip6addr: in6_addr, +} +#[test] +fn bindgen_test_layout_pfr_addr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfr_addr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfr_addr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfra_ip4addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_addr__bindgen_ty_1), + "::", + stringify!(_pfra_ip4addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfra_ip6addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_addr__bindgen_ty_1), + "::", + stringify!(_pfra_ip6addr) + ) + ); +} +#[test] +fn bindgen_test_layout_pfr_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pfr_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfr_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_u) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_u)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_af) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_net) as usize - ptr as usize }, + 17usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_net)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_not) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_not)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_fback) as usize - ptr as usize }, + 19usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_fback)) + ); +} +pub const PFR_DIR_IN: _bindgen_ty_16 = 0; +pub const PFR_DIR_OUT: _bindgen_ty_16 = 1; +pub const PFR_DIR_MAX: _bindgen_ty_16 = 2; +pub type _bindgen_ty_16 = ::std::os::raw::c_uint; +pub const PFR_OP_BLOCK: _bindgen_ty_17 = 0; +pub const PFR_OP_PASS: _bindgen_ty_17 = 1; +pub const PFR_OP_ADDR_MAX: _bindgen_ty_17 = 2; +pub const PFR_OP_TABLE_MAX: _bindgen_ty_17 = 3; +pub type _bindgen_ty_17 = ::std::os::raw::c_uint; +pub const PFR_TYPE_PACKETS: _bindgen_ty_18 = 0; +pub const PFR_TYPE_BYTES: _bindgen_ty_18 = 1; +pub const PFR_TYPE_MAX: _bindgen_ty_18 = 2; +pub type _bindgen_ty_18 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_astats { + pub pfras_a: pfr_addr, + pub pfras_packets: [[u_int64_t; 2usize]; 2usize], + pub pfras_bytes: [[u_int64_t; 2usize]; 2usize], + pub pfras_tzero: ::std::os::raw::c_long, +} +#[test] +fn bindgen_test_layout_pfr_astats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(pfr_astats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_astats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_a) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_astats), "::", stringify!(pfras_a)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_packets) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfr_astats), + "::", + stringify!(pfras_packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_bytes) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(pfr_astats), + "::", + stringify!(pfras_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_tzero) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(pfr_astats), + "::", + stringify!(pfras_tzero) + ) + ); +} +pub const PFR_REFCNT_RULE: _bindgen_ty_19 = 0; +pub const PFR_REFCNT_ANCHOR: _bindgen_ty_19 = 1; +pub const PFR_REFCNT_MAX: _bindgen_ty_19 = 2; +pub type _bindgen_ty_19 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_tstats { + pub pfrts_t: pfr_table, + pub pfrts_packets: [[u_int64_t; 3usize]; 2usize], + pub pfrts_bytes: [[u_int64_t; 3usize]; 2usize], + pub pfrts_match: u_int64_t, + pub pfrts_nomatch: u_int64_t, + pub pfrts_tzero: ::std::os::raw::c_long, + pub pfrts_cnt: ::std::os::raw::c_int, + pub pfrts_refcnt: [::std::os::raw::c_int; 2usize], +} +#[test] +fn bindgen_test_layout_pfr_tstats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1200usize, + concat!("Size of: ", stringify!(pfr_tstats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_tstats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_t) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_tstats), "::", stringify!(pfrts_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_packets) as usize - ptr as usize }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_bytes) as usize - ptr as usize }, + 1112usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_match) as usize - ptr as usize }, + 1160usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_match) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_nomatch) as usize - ptr as usize }, + 1168usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_nomatch) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_tzero) as usize - ptr as usize }, + 1176usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_tzero) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_cnt) as usize - ptr as usize }, + 1184usize, + concat!("Offset of field: ", stringify!(pfr_tstats), "::", stringify!(pfrts_cnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_refcnt) as usize - ptr as usize }, + 1188usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_refcnt) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union sockaddr_union { + pub sa: sockaddr, + pub sin: sockaddr_in, + pub sin6: sockaddr_in6, +} +#[test] +fn bindgen_test_layout_sockaddr_union() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 28usize, + concat!("Size of: ", stringify!(sockaddr_union)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_union)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_union), "::", stringify!(sa)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_union), "::", stringify!(sin)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_union), "::", stringify!(sin6)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_kcounters { + pub pfrkc_counters: counter_u64_t, + pub pfrkc_tzero: ::std::os::raw::c_long, +} +#[test] +fn bindgen_test_layout_pfr_kcounters() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfr_kcounters)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkc_counters) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_kcounters), + "::", + stringify!(pfrkc_counters) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkc_tzero) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfr_kcounters), + "::", + stringify!(pfrkc_tzero) + ) + ); +} +pub const pf_syncookies_mode_PF_SYNCOOKIES_NEVER: pf_syncookies_mode = 0; +pub const pf_syncookies_mode_PF_SYNCOOKIES_ALWAYS: pf_syncookies_mode = 1; +pub const pf_syncookies_mode_PF_SYNCOOKIES_ADAPTIVE: pf_syncookies_mode = 2; +pub const pf_syncookies_mode_PF_SYNCOOKIES_MODE_MAX: pf_syncookies_mode = 2; +pub type pf_syncookies_mode = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_divert { + pub addr: pf_divert__bindgen_ty_1, + pub port: u_int16_t, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_divert__bindgen_ty_1 { + pub ipv4: in_addr, + pub ipv6: in6_addr, +} +#[test] +fn bindgen_test_layout_pf_divert__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_divert__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_divert__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipv4) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_divert__bindgen_ty_1), + "::", + stringify!(ipv4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipv6) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_divert__bindgen_ty_1), + "::", + stringify!(ipv6) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_divert() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pf_divert)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_divert)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_divert), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_divert), "::", stringify!(port)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_pooladdr { + pub action: u_int32_t, + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub r_num: u_int32_t, + pub r_action: u_int8_t, + pub r_last: u_int8_t, + pub af: u_int8_t, + pub anchor: [::std::os::raw::c_char; 1024usize], + pub addr: pf_pooladdr, +} +#[test] +fn bindgen_test_layout_pfioc_pooladdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1136usize, + concat!("Size of: ", stringify!(pfioc_pooladdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_pooladdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(action) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(ticket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_pooladdr), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).r_num) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pfioc_pooladdr), "::", stringify!(r_num)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).r_action) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(r_action) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).r_last) as usize - ptr as usize }, + 17usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(r_last) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(pfioc_pooladdr), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 19usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 1048usize, + concat!("Offset of field: ", stringify!(pfioc_pooladdr), "::", stringify!(addr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_rule { + pub action: u_int32_t, + pub ticket: u_int32_t, + pub pool_ticket: u_int32_t, + pub nr: u_int32_t, + pub anchor: [::std::os::raw::c_char; 1024usize], + pub anchor_call: [::std::os::raw::c_char; 1024usize], + pub rule: pf_rule, +} +#[test] +fn bindgen_test_layout_pfioc_rule() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 3040usize, + concat!("Size of: ", stringify!(pfioc_rule)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(action)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pool_ticket) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_rule), + "::", + stringify!(pool_ticket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor_call) as usize - ptr as usize }, + 1040usize, + concat!( + "Offset of field: ", + stringify!(pfioc_rule), + "::", + stringify!(anchor_call) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 2064usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(rule)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_natlook { + pub saddr: pf_addr, + pub daddr: pf_addr, + pub rsaddr: pf_addr, + pub rdaddr: pf_addr, + pub sport: u_int16_t, + pub dport: u_int16_t, + pub rsport: u_int16_t, + pub rdport: u_int16_t, + pub af: sa_family_t, + pub proto: u_int8_t, + pub direction: u_int8_t, +} +#[test] +fn bindgen_test_layout_pfioc_natlook() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 76usize, + concat!("Size of: ", stringify!(pfioc_natlook)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_natlook)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).saddr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(saddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).daddr) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(daddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rsaddr) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rsaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdaddr) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rdaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sport) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(sport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dport) as usize - ptr as usize }, + 66usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(dport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rsport) as usize - ptr as usize }, + 68usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rsport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdport) as usize - ptr as usize }, + 70usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rdport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 73usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(proto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 74usize, + concat!( + "Offset of field: ", + stringify!(pfioc_natlook), + "::", + stringify!(direction) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_state { + pub state: pfsync_state_1301, +} +#[test] +fn bindgen_test_layout_pfioc_state() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 242usize, + concat!("Size of: ", stringify!(pfioc_state)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfioc_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_state), "::", stringify!(state)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_src_node_kill { + pub psnk_af: sa_family_t, + pub psnk_src: pf_rule_addr, + pub psnk_dst: pf_rule_addr, + pub psnk_killed: u_int, +} +#[test] +fn bindgen_test_layout_pfioc_src_node_kill() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(pfioc_src_node_kill)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_src_node_kill)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_af) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_af) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_src) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_src) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_dst) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_dst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_killed) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_killed) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_state_kill { + pub psk_pfcmp: pf_state_cmp, + pub psk_af: sa_family_t, + pub psk_proto: ::std::os::raw::c_int, + pub psk_src: pf_rule_addr, + pub psk_dst: pf_rule_addr, + pub psk_ifname: [::std::os::raw::c_char; 16usize], + pub psk_label: [::std::os::raw::c_char; 64usize], + pub psk_killed: u_int, +} +#[test] +fn bindgen_test_layout_pfioc_state_kill() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 224usize, + concat!("Size of: ", stringify!(pfioc_state_kill)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_state_kill)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_pfcmp) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_pfcmp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_af) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_af) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_proto) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_proto) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_src) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_src) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_dst) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_dst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_ifname) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_label) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_label) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_killed) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_killed) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_states { + pub ps_len: ::std::os::raw::c_int, + pub __bindgen_anon_1: pfioc_states__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfioc_states__bindgen_ty_1 { + pub ps_buf: *mut ::std::os::raw::c_void, + pub ps_states: *mut pfsync_state_1301, +} +#[test] +fn bindgen_test_layout_pfioc_states__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_states__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_states__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states__bindgen_ty_1), + "::", + stringify!(ps_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_states) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states__bindgen_ty_1), + "::", + stringify!(ps_states) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_states() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_states)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_states), "::", stringify!(ps_len)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_states_v2 { + pub ps_len: ::std::os::raw::c_int, + pub ps_req_version: u64, + pub __bindgen_anon_1: pfioc_states_v2__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfioc_states_v2__bindgen_ty_1 { + pub ps_buf: *mut ::std::os::raw::c_void, + pub ps_states: *mut pf_state_export, +} +#[test] +fn bindgen_test_layout_pfioc_states_v2__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_states_v2__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_states_v2__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states_v2__bindgen_ty_1), + "::", + stringify!(ps_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_states) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states_v2__bindgen_ty_1), + "::", + stringify!(ps_states) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_states_v2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pfioc_states_v2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_states_v2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states_v2), + "::", + stringify!(ps_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_req_version) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states_v2), + "::", + stringify!(ps_req_version) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_src_nodes { + pub psn_len: ::std::os::raw::c_int, + pub __bindgen_anon_1: pfioc_src_nodes__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfioc_src_nodes__bindgen_ty_1 { + pub psn_buf: *mut ::std::os::raw::c_void, + pub psn_src_nodes: *mut pf_src_node, +} +#[test] +fn bindgen_test_layout_pfioc_src_nodes__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_src_nodes__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_src_nodes__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psn_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes__bindgen_ty_1), + "::", + stringify!(psn_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psn_src_nodes) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes__bindgen_ty_1), + "::", + stringify!(psn_src_nodes) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_src_nodes() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_src_nodes)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_src_nodes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psn_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes), + "::", + stringify!(psn_len) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_if { + pub ifname: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_pfioc_if() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_if)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfioc_if)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_if), "::", stringify!(ifname)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_tm { + pub timeout: ::std::os::raw::c_int, + pub seconds: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfioc_tm() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_tm)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_tm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_tm), "::", stringify!(timeout)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seconds) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_tm), "::", stringify!(seconds)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_limit { + pub index: ::std::os::raw::c_int, + pub limit: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_pfioc_limit() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_limit)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_limit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).index) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_limit), "::", stringify!(index)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_limit), "::", stringify!(limit)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_altq_v0 { + pub action: u_int32_t, + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub altq: pf_altq_v0, +} +#[test] +fn bindgen_test_layout_pfioc_altq_v0() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 256usize, + concat!("Size of: ", stringify!(pfioc_altq_v0)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_altq_v0)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_altq_v0), "::", stringify!(action)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_altq_v0), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_altq_v0), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).altq) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_altq_v0), "::", stringify!(altq)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_altq_v1 { + pub action: u_int32_t, + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub version: u_int32_t, + pub altq: pf_altq_v1, +} +#[test] +fn bindgen_test_layout_pfioc_altq_v1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 304usize, + concat!("Size of: ", stringify!(pfioc_altq_v1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_altq_v1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_altq_v1), "::", stringify!(action)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_altq_v1), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_altq_v1), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pfioc_altq_v1), + "::", + stringify!(version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).altq) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_altq_v1), "::", stringify!(altq)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_qstats_v0 { + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub buf: *mut ::std::os::raw::c_void, + pub nbytes: ::std::os::raw::c_int, + pub scheduler: u_int8_t, +} +#[test] +fn bindgen_test_layout_pfioc_qstats_v0() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pfioc_qstats_v0)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_qstats_v0)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_qstats_v0), + "::", + stringify!(ticket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_qstats_v0), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).buf) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_qstats_v0), "::", stringify!(buf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nbytes) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfioc_qstats_v0), + "::", + stringify!(nbytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scheduler) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfioc_qstats_v0), + "::", + stringify!(scheduler) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_qstats_v1 { + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub buf: *mut ::std::os::raw::c_void, + pub nbytes: ::std::os::raw::c_int, + pub scheduler: u_int8_t, + pub version: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfioc_qstats_v1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pfioc_qstats_v1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_qstats_v1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_qstats_v1), + "::", + stringify!(ticket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_qstats_v1), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).buf) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_qstats_v1), "::", stringify!(buf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nbytes) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfioc_qstats_v1), + "::", + stringify!(nbytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scheduler) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfioc_qstats_v1), + "::", + stringify!(scheduler) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfioc_qstats_v1), + "::", + stringify!(version) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_ruleset { + pub nr: u_int32_t, + pub path: [::std::os::raw::c_char; 1024usize], + pub name: [::std::os::raw::c_char; 64usize], +} +#[test] +fn bindgen_test_layout_pfioc_ruleset() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1092usize, + concat!("Size of: ", stringify!(pfioc_ruleset)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_ruleset), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).path) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_ruleset), "::", stringify!(path)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, + 1028usize, + concat!("Offset of field: ", stringify!(pfioc_ruleset), "::", stringify!(name)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_trans { + pub size: ::std::os::raw::c_int, + pub esize: ::std::os::raw::c_int, + pub array: *mut pfioc_trans_pfioc_trans_e, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_trans_pfioc_trans_e { + pub rs_num: ::std::os::raw::c_int, + pub anchor: [::std::os::raw::c_char; 1024usize], + pub ticket: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfioc_trans_pfioc_trans_e() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1032usize, + concat!("Size of: ", stringify!(pfioc_trans_pfioc_trans_e)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_trans_pfioc_trans_e)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rs_num) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_trans_pfioc_trans_e), + "::", + stringify!(rs_num) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pfioc_trans_pfioc_trans_e), + "::", + stringify!(anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 1028usize, + concat!( + "Offset of field: ", + stringify!(pfioc_trans_pfioc_trans_e), + "::", + stringify!(ticket) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_trans() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_trans)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_trans)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).size) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_trans), "::", stringify!(size)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).esize) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_trans), "::", stringify!(esize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).array) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_trans), "::", stringify!(array)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_table { + pub pfrio_table: pfr_table, + pub pfrio_buffer: *mut ::std::os::raw::c_void, + pub pfrio_esize: ::std::os::raw::c_int, + pub pfrio_size: ::std::os::raw::c_int, + pub pfrio_size2: ::std::os::raw::c_int, + pub pfrio_nadd: ::std::os::raw::c_int, + pub pfrio_ndel: ::std::os::raw::c_int, + pub pfrio_nchange: ::std::os::raw::c_int, + pub pfrio_flags: ::std::os::raw::c_int, + pub pfrio_ticket: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfioc_table() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1104usize, + concat!("Size of: ", stringify!(pfioc_table)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_table)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_table) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_table) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_buffer) as usize - ptr as usize }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_buffer) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_esize) as usize - ptr as usize }, + 1072usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_esize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_size) as usize - ptr as usize }, + 1076usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_size2) as usize - ptr as usize }, + 1080usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_size2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_nadd) as usize - ptr as usize }, + 1084usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_nadd) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_ndel) as usize - ptr as usize }, + 1088usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_ndel) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_nchange) as usize - ptr as usize }, + 1092usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_nchange) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_flags) as usize - ptr as usize }, + 1096usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_ticket) as usize - ptr as usize }, + 1100usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_ticket) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_iface { + pub pfiio_name: [::std::os::raw::c_char; 16usize], + pub pfiio_buffer: *mut ::std::os::raw::c_void, + pub pfiio_esize: ::std::os::raw::c_int, + pub pfiio_size: ::std::os::raw::c_int, + pub pfiio_nzero: ::std::os::raw::c_int, + pub pfiio_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfioc_iface() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pfioc_iface)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_iface)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_buffer) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_buffer) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_esize) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_esize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_size) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_nzero) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_nzero) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_flags) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_flags) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ifspeed_v0 { + pub ifname: [::std::os::raw::c_char; 16usize], + pub baudrate: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_ifspeed_v0() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pf_ifspeed_v0)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_ifspeed_v0)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_ifspeed_v0), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).baudrate) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_ifspeed_v0), + "::", + stringify!(baudrate) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ifspeed_v1 { + pub ifname: [::std::os::raw::c_char; 16usize], + pub baudrate32: u_int32_t, + pub baudrate: u_int64_t, +} +#[test] +fn bindgen_test_layout_pf_ifspeed_v1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_ifspeed_v1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ifspeed_v1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_ifspeed_v1), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).baudrate32) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_ifspeed_v1), + "::", + stringify!(baudrate32) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).baudrate) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_ifspeed_v1), + "::", + stringify!(baudrate) + ) + ); +} +extern "C" { + pub fn pf_osfp_add(arg1: *mut pf_osfp_ioctl) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_osfp_flush(); +} +extern "C" { + pub fn pf_osfp_get(arg1: *mut pf_osfp_ioctl) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_osfp_match(arg1: *mut pf_os_fingerprint_pf_osfp_enlist, arg2: pf_osfp_t) -> ::std::os::raw::c_int; +} +pub type __builtin_va_list = [__va_list_tag; 1usize]; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __va_list_tag { + pub gp_offset: ::std::os::raw::c_uint, + pub fp_offset: ::std::os::raw::c_uint, + pub overflow_arg_area: *mut ::std::os::raw::c_void, + pub reg_save_area: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout___va_list_tag() { + const UNINIT: ::std::mem::MaybeUninit<__va_list_tag> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__va_list_tag>(), + 24usize, + concat!("Size of: ", stringify!(__va_list_tag)) + ); + assert_eq!( + ::std::mem::align_of::<__va_list_tag>(), + 8usize, + concat!("Alignment of ", stringify!(__va_list_tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gp_offset) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(gp_offset) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_offset) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(fp_offset) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).overflow_arg_area) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(overflow_arg_area) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reg_save_area) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(reg_save_area) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct witness { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct llentry { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifg_group { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_dynaddr { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_ktable { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_kstate { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_krule { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_krule_global { + pub _address: u8, +} diff --git a/tproxy_tokio/src/tcp/bsd/pfvar_bindgen_macos.rs b/tproxy_tokio/src/tcp/bsd/pfvar_bindgen_macos.rs new file mode 100644 index 0000000..e0f9945 --- /dev/null +++ b/tproxy_tokio/src/tcp/bsd/pfvar_bindgen_macos.rs @@ -0,0 +1,23530 @@ +// automatically generated by rust-bindgen 0.69.2 + +#[repr(C)] +#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)] +pub struct __BindgenBitfieldUnit { + storage: Storage, +} +impl __BindgenBitfieldUnit { + #[inline] + pub const fn new(storage: Storage) -> Self { + Self { storage } + } +} +impl __BindgenBitfieldUnit +where + Storage: AsRef<[u8]> + AsMut<[u8]>, +{ + #[inline] + pub fn get_bit(&self, index: usize) -> bool { + debug_assert!(index / 8 < self.storage.as_ref().len()); + let byte_index = index / 8; + let byte = self.storage.as_ref()[byte_index]; + let bit_index = if cfg!(target_endian = "big") { + 7 - (index % 8) + } else { + index % 8 + }; + let mask = 1 << bit_index; + byte & mask == mask + } + + #[inline] + pub fn set_bit(&mut self, index: usize, val: bool) { + debug_assert!(index / 8 < self.storage.as_ref().len()); + let byte_index = index / 8; + let byte = &mut self.storage.as_mut()[byte_index]; + let bit_index = if cfg!(target_endian = "big") { + 7 - (index % 8) + } else { + index % 8 + }; + let mask = 1 << bit_index; + if val { + *byte |= mask; + } else { + *byte &= !mask; + } + } + + #[inline] + pub fn get(&self, bit_offset: usize, bit_width: u8) -> u64 { + debug_assert!(bit_width <= 64); + debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); + debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); + let mut val = 0; + for i in 0..(bit_width as usize) { + if self.get_bit(i + bit_offset) { + let index = if cfg!(target_endian = "big") { + bit_width as usize - 1 - i + } else { + i + }; + val |= 1 << index; + } + } + val + } + + #[inline] + pub fn set(&mut self, bit_offset: usize, bit_width: u8, val: u64) { + debug_assert!(bit_width <= 64); + debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); + debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); + for i in 0..(bit_width as usize) { + let mask = 1 << i; + let val_bit_is_set = val & mask == mask; + let index = if cfg!(target_endian = "big") { + bit_width as usize - 1 - i + } else { + i + }; + self.set_bit(index + bit_offset, val_bit_is_set); + } + } +} +pub const __bool_true_false_are_defined: u32 = 1; +pub const true_: u32 = 1; +pub const false_: u32 = 0; +pub const BSD: u32 = 199506; +pub const BSD4_3: u32 = 1; +pub const BSD4_4: u32 = 1; +pub const NeXTBSD: u32 = 1995064; +pub const NeXTBSD4_0: u32 = 0; +pub const __DARWIN_UNIX03: u32 = 1; +pub const __DARWIN_64_BIT_INO_T: u32 = 1; +pub const __DARWIN_VERS_1050: u32 = 1; +pub const __DARWIN_NON_CANCELABLE: u32 = 0; +pub const __DARWIN_SUF_UNIX03: &[u8; 10] = b"$UNIX2003\0"; +pub const __DARWIN_SUF_64_BIT_INO_T: &[u8; 9] = b"$INODE64\0"; +pub const __DARWIN_SUF_1050: &[u8; 6] = b"$1050\0"; +pub const __DARWIN_SUF_EXTSN: &[u8; 14] = b"$DARWIN_EXTSN\0"; +pub const __DARWIN_C_ANSI: u32 = 4096; +pub const __DARWIN_C_FULL: u32 = 900000; +pub const __DARWIN_C_LEVEL: u32 = 900000; +pub const __STDC_WANT_LIB_EXT1__: u32 = 1; +pub const __DARWIN_NO_LONG_LONG: u32 = 0; +pub const _DARWIN_FEATURE_64_BIT_INODE: u32 = 1; +pub const _DARWIN_FEATURE_UNIX_CONFORMANCE: u32 = 3; +pub const __PTHREAD_SIZE__: u32 = 8176; +pub const __PTHREAD_ATTR_SIZE__: u32 = 56; +pub const __PTHREAD_MUTEXATTR_SIZE__: u32 = 8; +pub const __PTHREAD_MUTEX_SIZE__: u32 = 56; +pub const __PTHREAD_CONDATTR_SIZE__: u32 = 8; +pub const __PTHREAD_COND_SIZE__: u32 = 40; +pub const __PTHREAD_ONCE_SIZE__: u32 = 8; +pub const __PTHREAD_RWLOCK_SIZE__: u32 = 192; +pub const __PTHREAD_RWLOCKATTR_SIZE__: u32 = 16; +pub const _QUAD_HIGHWORD: u32 = 1; +pub const _QUAD_LOWWORD: u32 = 0; +pub const __DARWIN_LITTLE_ENDIAN: u32 = 1234; +pub const __DARWIN_BIG_ENDIAN: u32 = 4321; +pub const __DARWIN_PDP_ENDIAN: u32 = 3412; +pub const __DARWIN_BYTE_ORDER: u32 = 1234; +pub const LITTLE_ENDIAN: u32 = 1234; +pub const BIG_ENDIAN: u32 = 4321; +pub const PDP_ENDIAN: u32 = 3412; +pub const BYTE_ORDER: u32 = 1234; +pub const __API_TO_BE_DEPRECATED: u32 = 100000; +pub const __API_TO_BE_DEPRECATED_MACOS: u32 = 100000; +pub const __API_TO_BE_DEPRECATED_IOS: u32 = 100000; +pub const __API_TO_BE_DEPRECATED_MACCATALYST: u32 = 100000; +pub const __API_TO_BE_DEPRECATED_WATCHOS: u32 = 100000; +pub const __API_TO_BE_DEPRECATED_TVOS: u32 = 100000; +pub const __API_TO_BE_DEPRECATED_DRIVERKIT: u32 = 100000; +pub const __API_TO_BE_DEPRECATED_VISIONOS: u32 = 100000; +pub const __MAC_10_0: u32 = 1000; +pub const __MAC_10_1: u32 = 1010; +pub const __MAC_10_2: u32 = 1020; +pub const __MAC_10_3: u32 = 1030; +pub const __MAC_10_4: u32 = 1040; +pub const __MAC_10_5: u32 = 1050; +pub const __MAC_10_6: u32 = 1060; +pub const __MAC_10_7: u32 = 1070; +pub const __MAC_10_8: u32 = 1080; +pub const __MAC_10_9: u32 = 1090; +pub const __MAC_10_10: u32 = 101000; +pub const __MAC_10_10_2: u32 = 101002; +pub const __MAC_10_10_3: u32 = 101003; +pub const __MAC_10_11: u32 = 101100; +pub const __MAC_10_11_2: u32 = 101102; +pub const __MAC_10_11_3: u32 = 101103; +pub const __MAC_10_11_4: u32 = 101104; +pub const __MAC_10_12: u32 = 101200; +pub const __MAC_10_12_1: u32 = 101201; +pub const __MAC_10_12_2: u32 = 101202; +pub const __MAC_10_12_4: u32 = 101204; +pub const __MAC_10_13: u32 = 101300; +pub const __MAC_10_13_1: u32 = 101301; +pub const __MAC_10_13_2: u32 = 101302; +pub const __MAC_10_13_4: u32 = 101304; +pub const __MAC_10_14: u32 = 101400; +pub const __MAC_10_14_1: u32 = 101401; +pub const __MAC_10_14_4: u32 = 101404; +pub const __MAC_10_14_5: u32 = 101405; +pub const __MAC_10_14_6: u32 = 101406; +pub const __MAC_10_15: u32 = 101500; +pub const __MAC_10_15_1: u32 = 101501; +pub const __MAC_10_15_4: u32 = 101504; +pub const __MAC_10_16: u32 = 101600; +pub const __MAC_11_0: u32 = 110000; +pub const __MAC_11_1: u32 = 110100; +pub const __MAC_11_3: u32 = 110300; +pub const __MAC_11_4: u32 = 110400; +pub const __MAC_11_5: u32 = 110500; +pub const __MAC_11_6: u32 = 110600; +pub const __MAC_12_0: u32 = 120000; +pub const __MAC_12_1: u32 = 120100; +pub const __MAC_12_2: u32 = 120200; +pub const __MAC_12_3: u32 = 120300; +pub const __MAC_12_4: u32 = 120400; +pub const __MAC_12_5: u32 = 120500; +pub const __MAC_12_6: u32 = 120600; +pub const __MAC_12_7: u32 = 120700; +pub const __MAC_13_0: u32 = 130000; +pub const __MAC_13_1: u32 = 130100; +pub const __MAC_13_2: u32 = 130200; +pub const __MAC_13_3: u32 = 130300; +pub const __MAC_13_4: u32 = 130400; +pub const __MAC_13_5: u32 = 130500; +pub const __MAC_13_6: u32 = 130600; +pub const __MAC_14_0: u32 = 140000; +pub const __MAC_14_1: u32 = 140100; +pub const __MAC_14_2: u32 = 140200; +pub const __IPHONE_2_0: u32 = 20000; +pub const __IPHONE_2_1: u32 = 20100; +pub const __IPHONE_2_2: u32 = 20200; +pub const __IPHONE_3_0: u32 = 30000; +pub const __IPHONE_3_1: u32 = 30100; +pub const __IPHONE_3_2: u32 = 30200; +pub const __IPHONE_4_0: u32 = 40000; +pub const __IPHONE_4_1: u32 = 40100; +pub const __IPHONE_4_2: u32 = 40200; +pub const __IPHONE_4_3: u32 = 40300; +pub const __IPHONE_5_0: u32 = 50000; +pub const __IPHONE_5_1: u32 = 50100; +pub const __IPHONE_6_0: u32 = 60000; +pub const __IPHONE_6_1: u32 = 60100; +pub const __IPHONE_7_0: u32 = 70000; +pub const __IPHONE_7_1: u32 = 70100; +pub const __IPHONE_8_0: u32 = 80000; +pub const __IPHONE_8_1: u32 = 80100; +pub const __IPHONE_8_2: u32 = 80200; +pub const __IPHONE_8_3: u32 = 80300; +pub const __IPHONE_8_4: u32 = 80400; +pub const __IPHONE_9_0: u32 = 90000; +pub const __IPHONE_9_1: u32 = 90100; +pub const __IPHONE_9_2: u32 = 90200; +pub const __IPHONE_9_3: u32 = 90300; +pub const __IPHONE_10_0: u32 = 100000; +pub const __IPHONE_10_1: u32 = 100100; +pub const __IPHONE_10_2: u32 = 100200; +pub const __IPHONE_10_3: u32 = 100300; +pub const __IPHONE_11_0: u32 = 110000; +pub const __IPHONE_11_1: u32 = 110100; +pub const __IPHONE_11_2: u32 = 110200; +pub const __IPHONE_11_3: u32 = 110300; +pub const __IPHONE_11_4: u32 = 110400; +pub const __IPHONE_12_0: u32 = 120000; +pub const __IPHONE_12_1: u32 = 120100; +pub const __IPHONE_12_2: u32 = 120200; +pub const __IPHONE_12_3: u32 = 120300; +pub const __IPHONE_12_4: u32 = 120400; +pub const __IPHONE_13_0: u32 = 130000; +pub const __IPHONE_13_1: u32 = 130100; +pub const __IPHONE_13_2: u32 = 130200; +pub const __IPHONE_13_3: u32 = 130300; +pub const __IPHONE_13_4: u32 = 130400; +pub const __IPHONE_13_5: u32 = 130500; +pub const __IPHONE_13_6: u32 = 130600; +pub const __IPHONE_13_7: u32 = 130700; +pub const __IPHONE_14_0: u32 = 140000; +pub const __IPHONE_14_1: u32 = 140100; +pub const __IPHONE_14_2: u32 = 140200; +pub const __IPHONE_14_3: u32 = 140300; +pub const __IPHONE_14_5: u32 = 140500; +pub const __IPHONE_14_4: u32 = 140400; +pub const __IPHONE_14_6: u32 = 140600; +pub const __IPHONE_14_7: u32 = 140700; +pub const __IPHONE_14_8: u32 = 140800; +pub const __IPHONE_15_0: u32 = 150000; +pub const __IPHONE_15_1: u32 = 150100; +pub const __IPHONE_15_2: u32 = 150200; +pub const __IPHONE_15_3: u32 = 150300; +pub const __IPHONE_15_4: u32 = 150400; +pub const __IPHONE_15_5: u32 = 150500; +pub const __IPHONE_15_6: u32 = 150600; +pub const __IPHONE_16_0: u32 = 160000; +pub const __IPHONE_16_1: u32 = 160100; +pub const __IPHONE_16_2: u32 = 160200; +pub const __IPHONE_16_3: u32 = 160300; +pub const __IPHONE_16_4: u32 = 160400; +pub const __IPHONE_16_5: u32 = 160500; +pub const __IPHONE_16_6: u32 = 160600; +pub const __IPHONE_16_7: u32 = 160700; +pub const __IPHONE_17_0: u32 = 170000; +pub const __IPHONE_17_1: u32 = 170100; +pub const __IPHONE_17_2: u32 = 170200; +pub const __WATCHOS_1_0: u32 = 10000; +pub const __WATCHOS_2_0: u32 = 20000; +pub const __WATCHOS_2_1: u32 = 20100; +pub const __WATCHOS_2_2: u32 = 20200; +pub const __WATCHOS_3_0: u32 = 30000; +pub const __WATCHOS_3_1: u32 = 30100; +pub const __WATCHOS_3_1_1: u32 = 30101; +pub const __WATCHOS_3_2: u32 = 30200; +pub const __WATCHOS_4_0: u32 = 40000; +pub const __WATCHOS_4_1: u32 = 40100; +pub const __WATCHOS_4_2: u32 = 40200; +pub const __WATCHOS_4_3: u32 = 40300; +pub const __WATCHOS_5_0: u32 = 50000; +pub const __WATCHOS_5_1: u32 = 50100; +pub const __WATCHOS_5_2: u32 = 50200; +pub const __WATCHOS_5_3: u32 = 50300; +pub const __WATCHOS_6_0: u32 = 60000; +pub const __WATCHOS_6_1: u32 = 60100; +pub const __WATCHOS_6_2: u32 = 60200; +pub const __WATCHOS_7_0: u32 = 70000; +pub const __WATCHOS_7_1: u32 = 70100; +pub const __WATCHOS_7_2: u32 = 70200; +pub const __WATCHOS_7_3: u32 = 70300; +pub const __WATCHOS_7_4: u32 = 70400; +pub const __WATCHOS_7_5: u32 = 70500; +pub const __WATCHOS_7_6: u32 = 70600; +pub const __WATCHOS_8_0: u32 = 80000; +pub const __WATCHOS_8_1: u32 = 80100; +pub const __WATCHOS_8_3: u32 = 80300; +pub const __WATCHOS_8_4: u32 = 80400; +pub const __WATCHOS_8_5: u32 = 80500; +pub const __WATCHOS_8_6: u32 = 80600; +pub const __WATCHOS_8_7: u32 = 80700; +pub const __WATCHOS_9_0: u32 = 90000; +pub const __WATCHOS_9_1: u32 = 90100; +pub const __WATCHOS_9_2: u32 = 90200; +pub const __WATCHOS_9_3: u32 = 90300; +pub const __WATCHOS_9_4: u32 = 90400; +pub const __WATCHOS_9_5: u32 = 90500; +pub const __WATCHOS_9_6: u32 = 90600; +pub const __WATCHOS_10_0: u32 = 100000; +pub const __WATCHOS_10_1: u32 = 100100; +pub const __WATCHOS_10_2: u32 = 100200; +pub const __TVOS_9_0: u32 = 90000; +pub const __TVOS_9_1: u32 = 90100; +pub const __TVOS_9_2: u32 = 90200; +pub const __TVOS_10_0: u32 = 100000; +pub const __TVOS_10_0_1: u32 = 100001; +pub const __TVOS_10_1: u32 = 100100; +pub const __TVOS_10_2: u32 = 100200; +pub const __TVOS_11_0: u32 = 110000; +pub const __TVOS_11_1: u32 = 110100; +pub const __TVOS_11_2: u32 = 110200; +pub const __TVOS_11_3: u32 = 110300; +pub const __TVOS_11_4: u32 = 110400; +pub const __TVOS_12_0: u32 = 120000; +pub const __TVOS_12_1: u32 = 120100; +pub const __TVOS_12_2: u32 = 120200; +pub const __TVOS_12_3: u32 = 120300; +pub const __TVOS_12_4: u32 = 120400; +pub const __TVOS_13_0: u32 = 130000; +pub const __TVOS_13_2: u32 = 130200; +pub const __TVOS_13_3: u32 = 130300; +pub const __TVOS_13_4: u32 = 130400; +pub const __TVOS_14_0: u32 = 140000; +pub const __TVOS_14_1: u32 = 140100; +pub const __TVOS_14_2: u32 = 140200; +pub const __TVOS_14_3: u32 = 140300; +pub const __TVOS_14_5: u32 = 140500; +pub const __TVOS_14_6: u32 = 140600; +pub const __TVOS_14_7: u32 = 140700; +pub const __TVOS_15_0: u32 = 150000; +pub const __TVOS_15_1: u32 = 150100; +pub const __TVOS_15_2: u32 = 150200; +pub const __TVOS_15_3: u32 = 150300; +pub const __TVOS_15_4: u32 = 150400; +pub const __TVOS_15_5: u32 = 150500; +pub const __TVOS_15_6: u32 = 150600; +pub const __TVOS_16_0: u32 = 160000; +pub const __TVOS_16_1: u32 = 160100; +pub const __TVOS_16_2: u32 = 160200; +pub const __TVOS_16_3: u32 = 160300; +pub const __TVOS_16_4: u32 = 160400; +pub const __TVOS_16_5: u32 = 160500; +pub const __TVOS_16_6: u32 = 160600; +pub const __TVOS_17_0: u32 = 170000; +pub const __TVOS_17_1: u32 = 170100; +pub const __TVOS_17_2: u32 = 170200; +pub const __BRIDGEOS_2_0: u32 = 20000; +pub const __BRIDGEOS_3_0: u32 = 30000; +pub const __BRIDGEOS_3_1: u32 = 30100; +pub const __BRIDGEOS_3_4: u32 = 30400; +pub const __BRIDGEOS_4_0: u32 = 40000; +pub const __BRIDGEOS_4_1: u32 = 40100; +pub const __BRIDGEOS_5_0: u32 = 50000; +pub const __BRIDGEOS_5_1: u32 = 50100; +pub const __BRIDGEOS_5_3: u32 = 50300; +pub const __BRIDGEOS_6_0: u32 = 60000; +pub const __BRIDGEOS_6_2: u32 = 60200; +pub const __BRIDGEOS_6_4: u32 = 60400; +pub const __BRIDGEOS_6_5: u32 = 60500; +pub const __BRIDGEOS_6_6: u32 = 60600; +pub const __BRIDGEOS_7_0: u32 = 70000; +pub const __BRIDGEOS_7_1: u32 = 70100; +pub const __BRIDGEOS_7_2: u32 = 70200; +pub const __BRIDGEOS_7_3: u32 = 70300; +pub const __BRIDGEOS_7_4: u32 = 70400; +pub const __BRIDGEOS_7_6: u32 = 70600; +pub const __BRIDGEOS_8_0: u32 = 80000; +pub const __BRIDGEOS_8_1: u32 = 80100; +pub const __BRIDGEOS_8_2: u32 = 80200; +pub const __DRIVERKIT_19_0: u32 = 190000; +pub const __DRIVERKIT_20_0: u32 = 200000; +pub const __DRIVERKIT_21_0: u32 = 210000; +pub const __DRIVERKIT_22_0: u32 = 220000; +pub const __DRIVERKIT_22_4: u32 = 220400; +pub const __DRIVERKIT_22_5: u32 = 220500; +pub const __DRIVERKIT_22_6: u32 = 220600; +pub const __DRIVERKIT_23_0: u32 = 230000; +pub const __DRIVERKIT_23_1: u32 = 230100; +pub const __DRIVERKIT_23_2: u32 = 230200; +pub const __VISIONOS_1_0: u32 = 10000; +pub const MAC_OS_X_VERSION_10_0: u32 = 1000; +pub const MAC_OS_X_VERSION_10_1: u32 = 1010; +pub const MAC_OS_X_VERSION_10_2: u32 = 1020; +pub const MAC_OS_X_VERSION_10_3: u32 = 1030; +pub const MAC_OS_X_VERSION_10_4: u32 = 1040; +pub const MAC_OS_X_VERSION_10_5: u32 = 1050; +pub const MAC_OS_X_VERSION_10_6: u32 = 1060; +pub const MAC_OS_X_VERSION_10_7: u32 = 1070; +pub const MAC_OS_X_VERSION_10_8: u32 = 1080; +pub const MAC_OS_X_VERSION_10_9: u32 = 1090; +pub const MAC_OS_X_VERSION_10_10: u32 = 101000; +pub const MAC_OS_X_VERSION_10_10_2: u32 = 101002; +pub const MAC_OS_X_VERSION_10_10_3: u32 = 101003; +pub const MAC_OS_X_VERSION_10_11: u32 = 101100; +pub const MAC_OS_X_VERSION_10_11_2: u32 = 101102; +pub const MAC_OS_X_VERSION_10_11_3: u32 = 101103; +pub const MAC_OS_X_VERSION_10_11_4: u32 = 101104; +pub const MAC_OS_X_VERSION_10_12: u32 = 101200; +pub const MAC_OS_X_VERSION_10_12_1: u32 = 101201; +pub const MAC_OS_X_VERSION_10_12_2: u32 = 101202; +pub const MAC_OS_X_VERSION_10_12_4: u32 = 101204; +pub const MAC_OS_X_VERSION_10_13: u32 = 101300; +pub const MAC_OS_X_VERSION_10_13_1: u32 = 101301; +pub const MAC_OS_X_VERSION_10_13_2: u32 = 101302; +pub const MAC_OS_X_VERSION_10_13_4: u32 = 101304; +pub const MAC_OS_X_VERSION_10_14: u32 = 101400; +pub const MAC_OS_X_VERSION_10_14_1: u32 = 101401; +pub const MAC_OS_X_VERSION_10_14_4: u32 = 101404; +pub const MAC_OS_X_VERSION_10_14_5: u32 = 101405; +pub const MAC_OS_X_VERSION_10_14_6: u32 = 101406; +pub const MAC_OS_X_VERSION_10_15: u32 = 101500; +pub const MAC_OS_X_VERSION_10_15_1: u32 = 101501; +pub const MAC_OS_X_VERSION_10_15_4: u32 = 101504; +pub const MAC_OS_X_VERSION_10_16: u32 = 101600; +pub const MAC_OS_VERSION_11_0: u32 = 110000; +pub const MAC_OS_VERSION_11_1: u32 = 110100; +pub const MAC_OS_VERSION_11_3: u32 = 110300; +pub const MAC_OS_VERSION_11_4: u32 = 110400; +pub const MAC_OS_VERSION_11_5: u32 = 110500; +pub const MAC_OS_VERSION_11_6: u32 = 110600; +pub const MAC_OS_VERSION_12_0: u32 = 120000; +pub const MAC_OS_VERSION_12_1: u32 = 120100; +pub const MAC_OS_VERSION_12_2: u32 = 120200; +pub const MAC_OS_VERSION_12_3: u32 = 120300; +pub const MAC_OS_VERSION_12_4: u32 = 120400; +pub const MAC_OS_VERSION_12_5: u32 = 120500; +pub const MAC_OS_VERSION_12_6: u32 = 120600; +pub const MAC_OS_VERSION_12_7: u32 = 120700; +pub const MAC_OS_VERSION_13_0: u32 = 130000; +pub const MAC_OS_VERSION_13_1: u32 = 130100; +pub const MAC_OS_VERSION_13_2: u32 = 130200; +pub const MAC_OS_VERSION_13_3: u32 = 130300; +pub const MAC_OS_VERSION_13_4: u32 = 130400; +pub const MAC_OS_VERSION_13_5: u32 = 130500; +pub const MAC_OS_VERSION_13_6: u32 = 130600; +pub const MAC_OS_VERSION_14_0: u32 = 140000; +pub const MAC_OS_VERSION_14_1: u32 = 140100; +pub const MAC_OS_VERSION_14_2: u32 = 140200; +pub const __MAC_OS_X_VERSION_MAX_ALLOWED: u32 = 140200; +pub const __ENABLE_LEGACY_MAC_AVAILABILITY: u32 = 1; +pub const __DARWIN_FD_SETSIZE: u32 = 1024; +pub const __DARWIN_NBBY: u32 = 8; +pub const NBBY: u32 = 8; +pub const FD_SETSIZE: u32 = 1024; +pub const ARG_MAX: u32 = 1048576; +pub const CHILD_MAX: u32 = 266; +pub const GID_MAX: u32 = 2147483647; +pub const LINK_MAX: u32 = 32767; +pub const MAX_CANON: u32 = 1024; +pub const MAX_INPUT: u32 = 1024; +pub const NAME_MAX: u32 = 255; +pub const NGROUPS_MAX: u32 = 16; +pub const UID_MAX: u32 = 2147483647; +pub const OPEN_MAX: u32 = 10240; +pub const PATH_MAX: u32 = 1024; +pub const PIPE_BUF: u32 = 512; +pub const BC_BASE_MAX: u32 = 99; +pub const BC_DIM_MAX: u32 = 2048; +pub const BC_SCALE_MAX: u32 = 99; +pub const BC_STRING_MAX: u32 = 1000; +pub const CHARCLASS_NAME_MAX: u32 = 14; +pub const COLL_WEIGHTS_MAX: u32 = 2; +pub const EQUIV_CLASS_MAX: u32 = 2; +pub const EXPR_NEST_MAX: u32 = 32; +pub const LINE_MAX: u32 = 2048; +pub const RE_DUP_MAX: u32 = 255; +pub const NZERO: u32 = 20; +pub const MAXCOMLEN: u32 = 16; +pub const MAXINTERP: u32 = 64; +pub const MAXLOGNAME: u32 = 255; +pub const MAXUPRC: u32 = 266; +pub const NCARGS: u32 = 1048576; +pub const NGROUPS: u32 = 16; +pub const NOFILE: u32 = 256; +pub const NOGROUP: u32 = 65535; +pub const MAXHOSTNAMELEN: u32 = 256; +pub const MAXDOMNAMELEN: u32 = 256; +pub const NBPG: u32 = 4096; +pub const PGOFSET: u32 = 4095; +pub const PGSHIFT: u32 = 12; +pub const DEV_BSIZE: u32 = 512; +pub const DEV_BSHIFT: u32 = 9; +pub const BLKDEV_IOSIZE: u32 = 2048; +pub const MAXPHYS: u32 = 131072; +pub const CLSIZE: u32 = 1; +pub const CLSIZELOG2: u32 = 0; +pub const MSIZESHIFT: u32 = 8; +pub const MSIZE: u32 = 256; +pub const MCLSHIFT: u32 = 11; +pub const MCLBYTES: u32 = 2048; +pub const MBIGCLSHIFT: u32 = 12; +pub const MBIGCLBYTES: u32 = 4096; +pub const M16KCLSHIFT: u32 = 14; +pub const M16KCLBYTES: u32 = 16384; +pub const MCLOFSET: u32 = 2047; +pub const NMBCLUSTERS: u32 = 512; +pub const __DARWIN_CLK_TCK: u32 = 100; +pub const CHAR_BIT: u32 = 8; +pub const MB_LEN_MAX: u32 = 6; +pub const CLK_TCK: u32 = 100; +pub const SCHAR_MAX: u32 = 127; +pub const SCHAR_MIN: i32 = -128; +pub const UCHAR_MAX: u32 = 255; +pub const CHAR_MAX: u32 = 127; +pub const CHAR_MIN: i32 = -128; +pub const USHRT_MAX: u32 = 65535; +pub const SHRT_MAX: u32 = 32767; +pub const SHRT_MIN: i32 = -32768; +pub const UINT_MAX: u32 = 4294967295; +pub const INT_MAX: u32 = 2147483647; +pub const INT_MIN: i32 = -2147483648; +pub const ULONG_MAX: i32 = -1; +pub const LONG_MAX: u64 = 9223372036854775807; +pub const LONG_MIN: i64 = -9223372036854775808; +pub const ULLONG_MAX: i32 = -1; +pub const LLONG_MAX: u64 = 9223372036854775807; +pub const LLONG_MIN: i64 = -9223372036854775808; +pub const LONG_BIT: u32 = 64; +pub const SSIZE_MAX: u64 = 9223372036854775807; +pub const WORD_BIT: u32 = 32; +pub const SIZE_T_MAX: i32 = -1; +pub const UQUAD_MAX: i32 = -1; +pub const QUAD_MAX: u64 = 9223372036854775807; +pub const QUAD_MIN: i64 = -9223372036854775808; +pub const _POSIX_ARG_MAX: u32 = 4096; +pub const _POSIX_CHILD_MAX: u32 = 25; +pub const _POSIX_LINK_MAX: u32 = 8; +pub const _POSIX_MAX_CANON: u32 = 255; +pub const _POSIX_MAX_INPUT: u32 = 255; +pub const _POSIX_NAME_MAX: u32 = 14; +pub const _POSIX_NGROUPS_MAX: u32 = 8; +pub const _POSIX_OPEN_MAX: u32 = 20; +pub const _POSIX_PATH_MAX: u32 = 256; +pub const _POSIX_PIPE_BUF: u32 = 512; +pub const _POSIX_SSIZE_MAX: u32 = 32767; +pub const _POSIX_STREAM_MAX: u32 = 8; +pub const _POSIX_TZNAME_MAX: u32 = 6; +pub const _POSIX2_BC_BASE_MAX: u32 = 99; +pub const _POSIX2_BC_DIM_MAX: u32 = 2048; +pub const _POSIX2_BC_SCALE_MAX: u32 = 99; +pub const _POSIX2_BC_STRING_MAX: u32 = 1000; +pub const _POSIX2_EQUIV_CLASS_MAX: u32 = 2; +pub const _POSIX2_EXPR_NEST_MAX: u32 = 32; +pub const _POSIX2_LINE_MAX: u32 = 2048; +pub const _POSIX2_RE_DUP_MAX: u32 = 255; +pub const _POSIX_AIO_LISTIO_MAX: u32 = 2; +pub const _POSIX_AIO_MAX: u32 = 1; +pub const _POSIX_DELAYTIMER_MAX: u32 = 32; +pub const _POSIX_MQ_OPEN_MAX: u32 = 8; +pub const _POSIX_MQ_PRIO_MAX: u32 = 32; +pub const _POSIX_RTSIG_MAX: u32 = 8; +pub const _POSIX_SEM_NSEMS_MAX: u32 = 256; +pub const _POSIX_SEM_VALUE_MAX: u32 = 32767; +pub const _POSIX_SIGQUEUE_MAX: u32 = 32; +pub const _POSIX_TIMER_MAX: u32 = 32; +pub const _POSIX_CLOCKRES_MIN: u32 = 20000000; +pub const _POSIX_THREAD_DESTRUCTOR_ITERATIONS: u32 = 4; +pub const _POSIX_THREAD_KEYS_MAX: u32 = 128; +pub const _POSIX_THREAD_THREADS_MAX: u32 = 64; +pub const PTHREAD_DESTRUCTOR_ITERATIONS: u32 = 4; +pub const PTHREAD_KEYS_MAX: u32 = 512; +pub const PTHREAD_STACK_MIN: u32 = 8192; +pub const _POSIX_HOST_NAME_MAX: u32 = 255; +pub const _POSIX_LOGIN_NAME_MAX: u32 = 9; +pub const _POSIX_SS_REPL_MAX: u32 = 4; +pub const _POSIX_SYMLINK_MAX: u32 = 255; +pub const _POSIX_SYMLOOP_MAX: u32 = 8; +pub const _POSIX_TRACE_EVENT_NAME_MAX: u32 = 30; +pub const _POSIX_TRACE_NAME_MAX: u32 = 8; +pub const _POSIX_TRACE_SYS_MAX: u32 = 8; +pub const _POSIX_TRACE_USER_EVENT_MAX: u32 = 32; +pub const _POSIX_TTY_NAME_MAX: u32 = 9; +pub const _POSIX2_CHARCLASS_NAME_MAX: u32 = 14; +pub const _POSIX2_COLL_WEIGHTS_MAX: u32 = 2; +pub const _POSIX_RE_DUP_MAX: u32 = 255; +pub const OFF_MIN: i64 = -9223372036854775808; +pub const OFF_MAX: u64 = 9223372036854775807; +pub const PASS_MAX: u32 = 128; +pub const NL_ARGMAX: u32 = 9; +pub const NL_LANGMAX: u32 = 14; +pub const NL_MSGMAX: u32 = 32767; +pub const NL_NMAX: u32 = 1; +pub const NL_SETMAX: u32 = 255; +pub const NL_TEXTMAX: u32 = 2048; +pub const _XOPEN_IOV_MAX: u32 = 16; +pub const IOV_MAX: u32 = 1024; +pub const _XOPEN_NAME_MAX: u32 = 255; +pub const _XOPEN_PATH_MAX: u32 = 1024; +pub const __DARWIN_NSIG: u32 = 32; +pub const NSIG: u32 = 32; +pub const _I386_SIGNAL_H_: u32 = 1; +pub const SIGHUP: u32 = 1; +pub const SIGINT: u32 = 2; +pub const SIGQUIT: u32 = 3; +pub const SIGILL: u32 = 4; +pub const SIGTRAP: u32 = 5; +pub const SIGABRT: u32 = 6; +pub const SIGIOT: u32 = 6; +pub const SIGEMT: u32 = 7; +pub const SIGFPE: u32 = 8; +pub const SIGKILL: u32 = 9; +pub const SIGBUS: u32 = 10; +pub const SIGSEGV: u32 = 11; +pub const SIGSYS: u32 = 12; +pub const SIGPIPE: u32 = 13; +pub const SIGALRM: u32 = 14; +pub const SIGTERM: u32 = 15; +pub const SIGURG: u32 = 16; +pub const SIGSTOP: u32 = 17; +pub const SIGTSTP: u32 = 18; +pub const SIGCONT: u32 = 19; +pub const SIGCHLD: u32 = 20; +pub const SIGTTIN: u32 = 21; +pub const SIGTTOU: u32 = 22; +pub const SIGIO: u32 = 23; +pub const SIGXCPU: u32 = 24; +pub const SIGXFSZ: u32 = 25; +pub const SIGVTALRM: u32 = 26; +pub const SIGPROF: u32 = 27; +pub const SIGWINCH: u32 = 28; +pub const SIGINFO: u32 = 29; +pub const SIGUSR1: u32 = 30; +pub const SIGUSR2: u32 = 31; +pub const FP_PREC_24B: u32 = 0; +pub const FP_PREC_53B: u32 = 2; +pub const FP_PREC_64B: u32 = 3; +pub const FP_RND_NEAR: u32 = 0; +pub const FP_RND_DOWN: u32 = 1; +pub const FP_RND_UP: u32 = 2; +pub const FP_CHOP: u32 = 3; +pub const FP_STATE_BYTES: u32 = 512; +pub const _X86_INSTRUCTION_STATE_MAX_INSN_BYTES: u32 = 2380; +pub const _X86_INSTRUCTION_STATE_CACHELINE_SIZE: u32 = 64; +pub const __LASTBRANCH_MAX: u32 = 32; +pub const SIGEV_NONE: u32 = 0; +pub const SIGEV_SIGNAL: u32 = 1; +pub const SIGEV_THREAD: u32 = 3; +pub const ILL_NOOP: u32 = 0; +pub const ILL_ILLOPC: u32 = 1; +pub const ILL_ILLTRP: u32 = 2; +pub const ILL_PRVOPC: u32 = 3; +pub const ILL_ILLOPN: u32 = 4; +pub const ILL_ILLADR: u32 = 5; +pub const ILL_PRVREG: u32 = 6; +pub const ILL_COPROC: u32 = 7; +pub const ILL_BADSTK: u32 = 8; +pub const FPE_NOOP: u32 = 0; +pub const FPE_FLTDIV: u32 = 1; +pub const FPE_FLTOVF: u32 = 2; +pub const FPE_FLTUND: u32 = 3; +pub const FPE_FLTRES: u32 = 4; +pub const FPE_FLTINV: u32 = 5; +pub const FPE_FLTSUB: u32 = 6; +pub const FPE_INTDIV: u32 = 7; +pub const FPE_INTOVF: u32 = 8; +pub const SEGV_NOOP: u32 = 0; +pub const SEGV_MAPERR: u32 = 1; +pub const SEGV_ACCERR: u32 = 2; +pub const BUS_NOOP: u32 = 0; +pub const BUS_ADRALN: u32 = 1; +pub const BUS_ADRERR: u32 = 2; +pub const BUS_OBJERR: u32 = 3; +pub const TRAP_BRKPT: u32 = 1; +pub const TRAP_TRACE: u32 = 2; +pub const CLD_NOOP: u32 = 0; +pub const CLD_EXITED: u32 = 1; +pub const CLD_KILLED: u32 = 2; +pub const CLD_DUMPED: u32 = 3; +pub const CLD_TRAPPED: u32 = 4; +pub const CLD_STOPPED: u32 = 5; +pub const CLD_CONTINUED: u32 = 6; +pub const POLL_IN: u32 = 1; +pub const POLL_OUT: u32 = 2; +pub const POLL_MSG: u32 = 3; +pub const POLL_ERR: u32 = 4; +pub const POLL_PRI: u32 = 5; +pub const POLL_HUP: u32 = 6; +pub const SA_ONSTACK: u32 = 1; +pub const SA_RESTART: u32 = 2; +pub const SA_RESETHAND: u32 = 4; +pub const SA_NOCLDSTOP: u32 = 8; +pub const SA_NODEFER: u32 = 16; +pub const SA_NOCLDWAIT: u32 = 32; +pub const SA_SIGINFO: u32 = 64; +pub const SA_USERTRAMP: u32 = 256; +pub const SA_64REGSET: u32 = 512; +pub const SA_USERSPACE_MASK: u32 = 127; +pub const SIG_BLOCK: u32 = 1; +pub const SIG_UNBLOCK: u32 = 2; +pub const SIG_SETMASK: u32 = 3; +pub const SI_USER: u32 = 65537; +pub const SI_QUEUE: u32 = 65538; +pub const SI_TIMER: u32 = 65539; +pub const SI_ASYNCIO: u32 = 65540; +pub const SI_MESGQ: u32 = 65541; +pub const SS_ONSTACK: u32 = 1; +pub const SS_DISABLE: u32 = 4; +pub const MINSIGSTKSZ: u32 = 32768; +pub const SIGSTKSZ: u32 = 131072; +pub const SV_ONSTACK: u32 = 1; +pub const SV_INTERRUPT: u32 = 2; +pub const SV_RESETHAND: u32 = 4; +pub const SV_NODEFER: u32 = 16; +pub const SV_NOCLDSTOP: u32 = 8; +pub const SV_SIGINFO: u32 = 64; +pub const PSWP: u32 = 0; +pub const PVM: u32 = 4; +pub const PINOD: u32 = 8; +pub const PRIBIO: u32 = 16; +pub const PVFS: u32 = 20; +pub const PZERO: u32 = 22; +pub const PSOCK: u32 = 24; +pub const PWAIT: u32 = 32; +pub const PLOCK: u32 = 36; +pub const PPAUSE: u32 = 40; +pub const PUSER: u32 = 50; +pub const MAXPRI: u32 = 127; +pub const PRIMASK: u32 = 255; +pub const PCATCH: u32 = 256; +pub const PTTYBLOCK: u32 = 512; +pub const PDROP: u32 = 1024; +pub const PSPIN: u32 = 2048; +pub const CMASK: u32 = 18; +pub const CLBYTES: u32 = 4096; +pub const CLOFSET: u32 = 4095; +pub const CLOFF: u32 = 4095; +pub const CLSHIFT: u32 = 12; +pub const CBLOCK: u32 = 64; +pub const CBQSIZE: u32 = 8; +pub const CROUND: u32 = 63; +pub const MAXBSIZE: u32 = 1048576; +pub const MAXPHYSIO: u32 = 131072; +pub const MAXFRAG: u32 = 8; +pub const MAXPHYSIO_WIRED: u32 = 16777216; +pub const MAXPATHLEN: u32 = 1024; +pub const MAXSYMLINKS: u32 = 32; +pub const FSHIFT: u32 = 11; +pub const FSCALE: u32 = 2048; +pub const SPLAY_NEGINF: i32 = -1; +pub const SPLAY_INF: u32 = 1; +pub const RB_BLACK: u32 = 0; +pub const RB_RED: u32 = 1; +pub const RB_NEGINF: i32 = -1; +pub const RB_INF: u32 = 1; +pub const RNF_NORMAL: u32 = 1; +pub const RNF_ROOT: u32 = 2; +pub const RNF_ACTIVE: u32 = 4; +pub const __WORDSIZE: u32 = 64; +pub const INT8_MAX: u32 = 127; +pub const INT16_MAX: u32 = 32767; +pub const INT32_MAX: u32 = 2147483647; +pub const INT64_MAX: u64 = 9223372036854775807; +pub const INT8_MIN: i32 = -128; +pub const INT16_MIN: i32 = -32768; +pub const INT32_MIN: i32 = -2147483648; +pub const INT64_MIN: i64 = -9223372036854775808; +pub const UINT8_MAX: u32 = 255; +pub const UINT16_MAX: u32 = 65535; +pub const UINT32_MAX: u32 = 4294967295; +pub const UINT64_MAX: i32 = -1; +pub const INT_LEAST8_MIN: i32 = -128; +pub const INT_LEAST16_MIN: i32 = -32768; +pub const INT_LEAST32_MIN: i32 = -2147483648; +pub const INT_LEAST64_MIN: i64 = -9223372036854775808; +pub const INT_LEAST8_MAX: u32 = 127; +pub const INT_LEAST16_MAX: u32 = 32767; +pub const INT_LEAST32_MAX: u32 = 2147483647; +pub const INT_LEAST64_MAX: u64 = 9223372036854775807; +pub const UINT_LEAST8_MAX: u32 = 255; +pub const UINT_LEAST16_MAX: u32 = 65535; +pub const UINT_LEAST32_MAX: u32 = 4294967295; +pub const UINT_LEAST64_MAX: i32 = -1; +pub const INT_FAST8_MIN: i32 = -128; +pub const INT_FAST16_MIN: i32 = -32768; +pub const INT_FAST32_MIN: i32 = -2147483648; +pub const INT_FAST64_MIN: i64 = -9223372036854775808; +pub const INT_FAST8_MAX: u32 = 127; +pub const INT_FAST16_MAX: u32 = 32767; +pub const INT_FAST32_MAX: u32 = 2147483647; +pub const INT_FAST64_MAX: u64 = 9223372036854775807; +pub const UINT_FAST8_MAX: u32 = 255; +pub const UINT_FAST16_MAX: u32 = 65535; +pub const UINT_FAST32_MAX: u32 = 4294967295; +pub const UINT_FAST64_MAX: i32 = -1; +pub const INTPTR_MAX: u64 = 9223372036854775807; +pub const INTPTR_MIN: i64 = -9223372036854775808; +pub const UINTPTR_MAX: i32 = -1; +pub const SIZE_MAX: i32 = -1; +pub const RSIZE_MAX: i32 = -1; +pub const WINT_MIN: i32 = -2147483648; +pub const WINT_MAX: u32 = 2147483647; +pub const SIG_ATOMIC_MIN: i32 = -2147483648; +pub const SIG_ATOMIC_MAX: u32 = 2147483647; +pub const KEV_INET_SUBCLASS: u32 = 1; +pub const KEV_INET_NEW_ADDR: u32 = 1; +pub const KEV_INET_CHANGED_ADDR: u32 = 2; +pub const KEV_INET_ADDR_DELETED: u32 = 3; +pub const KEV_INET_SIFDSTADDR: u32 = 4; +pub const KEV_INET_SIFBRDADDR: u32 = 5; +pub const KEV_INET_SIFNETMASK: u32 = 6; +pub const KEV_INET_ARPCOLLISION: u32 = 7; +pub const KEV_INET_PORTINUSE: u32 = 8; +pub const KEV_INET_ARPRTRFAILURE: u32 = 9; +pub const KEV_INET_ARPRTRALIVE: u32 = 10; +pub const KEV_DL_SUBCLASS: u32 = 2; +pub const KEV_DL_SIFFLAGS: u32 = 1; +pub const KEV_DL_SIFMETRICS: u32 = 2; +pub const KEV_DL_SIFMTU: u32 = 3; +pub const KEV_DL_SIFPHYS: u32 = 4; +pub const KEV_DL_SIFMEDIA: u32 = 5; +pub const KEV_DL_SIFGENERIC: u32 = 6; +pub const KEV_DL_ADDMULTI: u32 = 7; +pub const KEV_DL_DELMULTI: u32 = 8; +pub const KEV_DL_IF_ATTACHED: u32 = 9; +pub const KEV_DL_IF_DETACHING: u32 = 10; +pub const KEV_DL_IF_DETACHED: u32 = 11; +pub const KEV_DL_LINK_OFF: u32 = 12; +pub const KEV_DL_LINK_ON: u32 = 13; +pub const KEV_DL_PROTO_ATTACHED: u32 = 14; +pub const KEV_DL_PROTO_DETACHED: u32 = 15; +pub const KEV_DL_LINK_ADDRESS_CHANGED: u32 = 16; +pub const KEV_DL_WAKEFLAGS_CHANGED: u32 = 17; +pub const KEV_DL_IF_IDLE_ROUTE_REFCNT: u32 = 18; +pub const KEV_DL_IFCAP_CHANGED: u32 = 19; +pub const KEV_DL_LINK_QUALITY_METRIC_CHANGED: u32 = 20; +pub const KEV_DL_NODE_PRESENCE: u32 = 21; +pub const KEV_DL_NODE_ABSENCE: u32 = 22; +pub const KEV_DL_MASTER_ELECTED: u32 = 23; +pub const KEV_DL_ISSUES: u32 = 24; +pub const KEV_DL_IFDELEGATE_CHANGED: u32 = 25; +pub const KEV_DL_AWDL_RESTRICTED: u32 = 26; +pub const KEV_DL_AWDL_UNRESTRICTED: u32 = 27; +pub const KEV_DL_RRC_STATE_CHANGED: u32 = 28; +pub const KEV_DL_QOS_MODE_CHANGED: u32 = 29; +pub const KEV_DL_LOW_POWER_MODE_CHANGED: u32 = 30; +pub const KEV_NETPOLICY_SUBCLASS: u32 = 3; +pub const KEV_NETPOLICY_IFDENIED: u32 = 1; +pub const KEV_NETPOLICY_IFFAILED: u32 = 2; +pub const KEV_NETPOLICY_NETDENIED: u32 = 3; +pub const NETPOLICY_NETWORKTYPE_LOCAL: u32 = 1; +pub const KEV_SOCKET_SUBCLASS: u32 = 4; +pub const KEV_SOCKET_CLOSED: u32 = 1; +pub const KEV_INET6_SUBCLASS: u32 = 6; +pub const KEV_INET6_NEW_USER_ADDR: u32 = 1; +pub const KEV_INET6_CHANGED_ADDR: u32 = 2; +pub const KEV_INET6_ADDR_DELETED: u32 = 3; +pub const KEV_INET6_NEW_LL_ADDR: u32 = 4; +pub const KEV_INET6_NEW_RTADV_ADDR: u32 = 5; +pub const KEV_INET6_DEFROUTER: u32 = 6; +pub const KEV_INET6_REQUEST_NAT64_PREFIX: u32 = 7; +pub const KEV_ND6_SUBCLASS: u32 = 7; +pub const KEV_ND6_RA: u32 = 1; +pub const KEV_ND6_NDFAILURE: u32 = 2; +pub const KEV_ND6_NDALIVE: u32 = 3; +pub const KEV_ND6_DAD_FAILURE: u32 = 4; +pub const KEV_ND6_DAD_SUCCESS: u32 = 5; +pub const KEV_ND6_ADDR_DETACHED: u32 = 6; +pub const KEV_ND6_ADDR_DEPRECATED: u32 = 7; +pub const KEV_ND6_ADDR_EXPIRED: u32 = 8; +pub const KEV_ND6_RTR_EXPIRED: u32 = 9; +pub const KEV_ND6_PFX_EXPIRED: u32 = 10; +pub const KEV_NECP_SUBCLASS: u32 = 8; +pub const KEV_NECP_POLICIES_CHANGED: u32 = 1; +pub const KEV_NETAGENT_SUBCLASS: u32 = 9; +pub const KEV_NETAGENT_REGISTERED: u32 = 1; +pub const KEV_NETAGENT_UNREGISTERED: u32 = 2; +pub const KEV_NETAGENT_UPDATED: u32 = 3; +pub const KEV_NETAGENT_UPDATED_INTERFACES: u32 = 4; +pub const KEV_LOG_SUBCLASS: u32 = 10; +pub const IPFWLOGEVENT: u32 = 0; +pub const KEV_NETEVENT_SUBCLASS: u32 = 11; +pub const KEV_NETEVENT_APNFALLBACK: u32 = 1; +pub const KEV_NETEVENT_CLAT46_EVENT: u32 = 2; +pub const KEV_MPTCP_SUBCLASS: u32 = 12; +pub const KEV_MPTCP_CELLUSE: u32 = 1; +pub const KEV_IPSEC_SUBCLASS: u32 = 13; +pub const KEV_IPSEC_WAKE_PACKET: u32 = 1; +pub const SOCK_STREAM: u32 = 1; +pub const SOCK_DGRAM: u32 = 2; +pub const SOCK_RAW: u32 = 3; +pub const SOCK_RDM: u32 = 4; +pub const SOCK_SEQPACKET: u32 = 5; +pub const SO_DEBUG: u32 = 1; +pub const SO_ACCEPTCONN: u32 = 2; +pub const SO_REUSEADDR: u32 = 4; +pub const SO_KEEPALIVE: u32 = 8; +pub const SO_DONTROUTE: u32 = 16; +pub const SO_BROADCAST: u32 = 32; +pub const SO_USELOOPBACK: u32 = 64; +pub const SO_LINGER: u32 = 128; +pub const SO_OOBINLINE: u32 = 256; +pub const SO_REUSEPORT: u32 = 512; +pub const SO_TIMESTAMP: u32 = 1024; +pub const SO_TIMESTAMP_MONOTONIC: u32 = 2048; +pub const SO_DONTTRUNC: u32 = 8192; +pub const SO_WANTMORE: u32 = 16384; +pub const SO_WANTOOBFLAG: u32 = 32768; +pub const SO_NOWAKEFROMSLEEP: u32 = 65536; +pub const SO_NOAPNFALLBK: u32 = 131072; +pub const SO_TIMESTAMP_CONTINUOUS: u32 = 262144; +pub const SO_SNDBUF: u32 = 4097; +pub const SO_RCVBUF: u32 = 4098; +pub const SO_SNDLOWAT: u32 = 4099; +pub const SO_RCVLOWAT: u32 = 4100; +pub const SO_SNDTIMEO: u32 = 4101; +pub const SO_RCVTIMEO: u32 = 4102; +pub const SO_ERROR: u32 = 4103; +pub const SO_TYPE: u32 = 4104; +pub const SO_LABEL: u32 = 4112; +pub const SO_PEERLABEL: u32 = 4113; +pub const SO_NREAD: u32 = 4128; +pub const SO_NKE: u32 = 4129; +pub const SO_NOSIGPIPE: u32 = 4130; +pub const SO_NOADDRERR: u32 = 4131; +pub const SO_NWRITE: u32 = 4132; +pub const SO_REUSESHAREUID: u32 = 4133; +pub const SO_NOTIFYCONFLICT: u32 = 4134; +pub const SO_UPCALLCLOSEWAIT: u32 = 4135; +pub const SO_LINGER_SEC: u32 = 4224; +pub const SO_RESTRICTIONS: u32 = 4225; +pub const SO_RESTRICT_DENY_IN: u32 = 1; +pub const SO_RESTRICT_DENY_OUT: u32 = 2; +pub const SO_RESTRICT_DENY_CELLULAR: u32 = 4; +pub const SO_RESTRICT_DENY_EXPENSIVE: u32 = 8; +pub const SO_RESTRICT_DENY_CONSTRAINED: u32 = 16; +pub const SO_RANDOMPORT: u32 = 4226; +pub const SO_NP_EXTENSIONS: u32 = 4227; +pub const SO_EXECPATH: u32 = 4229; +pub const SO_TRAFFIC_CLASS: u32 = 4230; +pub const SO_TC_BK_SYS: u32 = 100; +pub const SO_TC_BK: u32 = 200; +pub const SO_TC_BE: u32 = 0; +pub const SO_TC_RD: u32 = 300; +pub const SO_TC_OAM: u32 = 400; +pub const SO_TC_AV: u32 = 500; +pub const SO_TC_RV: u32 = 600; +pub const SO_TC_VI: u32 = 700; +pub const SO_TC_VO: u32 = 800; +pub const SO_TC_CTL: u32 = 900; +pub const SO_TC_MAX: u32 = 10; +pub const TRAFFIC_MGT_SO_BACKGROUND: u32 = 1; +pub const TRAFFIC_MGT_TCP_RECVBG: u32 = 2; +pub const SO_RECV_TRAFFIC_CLASS: u32 = 4231; +pub const SO_TRAFFIC_CLASS_DBG: u32 = 4232; +pub const SO_OPTION_UNUSED_0: u32 = 4233; +pub const SO_PRIVILEGED_TRAFFIC_CLASS: u32 = 4240; +pub const SO_DEFUNCTIT: u32 = 4241; +pub const SO_DEFUNCTOK: u32 = 4352; +pub const SO_ISDEFUNCT: u32 = 4353; +pub const SO_OPPORTUNISTIC: u32 = 4354; +pub const SO_FLUSH: u32 = 4355; +pub const SO_TC_ALL: i32 = -1; +pub const SO_RECV_ANYIF: u32 = 4356; +pub const SO_TRAFFIC_MGT_BACKGROUND: u32 = 4357; +pub const SO_FLOW_DIVERT_TOKEN: u32 = 4358; +pub const SO_DELEGATED: u32 = 4359; +pub const SO_DELEGATED_UUID: u32 = 4360; +pub const SO_NECP_ATTRIBUTES: u32 = 4361; +pub const SO_CFIL_SOCK_ID: u32 = 4368; +pub const SO_NECP_CLIENTUUID: u32 = 4369; +pub const SO_NUMRCVPKT: u32 = 4370; +pub const SO_AWDL_UNRESTRICTED: u32 = 4371; +pub const SO_EXTENDED_BK_IDLE: u32 = 4372; +pub const SO_MARK_CELLFALLBACK: u32 = 4373; +pub const SO_NET_SERVICE_TYPE: u32 = 4374; +pub const SO_QOSMARKING_POLICY_OVERRIDE: u32 = 4375; +pub const SO_INTCOPROC_ALLOW: u32 = 4376; +pub const SO_NETSVC_MARKING_LEVEL: u32 = 4377; +pub const SO_NECP_LISTENUUID: u32 = 4384; +pub const SO_MPKL_SEND_INFO: u32 = 4386; +pub const SO_STATISTICS_EVENT: u32 = 4387; +pub const SO_WANT_KEV_SOCKET_CLOSED: u32 = 4388; +pub const NET_SERVICE_TYPE_BE: u32 = 0; +pub const NET_SERVICE_TYPE_BK: u32 = 1; +pub const NET_SERVICE_TYPE_SIG: u32 = 2; +pub const NET_SERVICE_TYPE_VI: u32 = 3; +pub const NET_SERVICE_TYPE_VO: u32 = 4; +pub const NET_SERVICE_TYPE_RV: u32 = 5; +pub const NET_SERVICE_TYPE_AV: u32 = 6; +pub const NET_SERVICE_TYPE_OAM: u32 = 7; +pub const NET_SERVICE_TYPE_RD: u32 = 8; +pub const _NET_SERVICE_TYPE_COUNT: u32 = 9; +pub const SO_TC_NET_SERVICE_OFFSET: u32 = 10000; +pub const SO_TC_NETSVC_SIG: u32 = 10002; +pub const NETSVC_MRKNG_UNKNOWN: u32 = 0; +pub const NETSVC_MRKNG_LVL_L2: u32 = 1; +pub const NETSVC_MRKNG_LVL_L3L2_ALL: u32 = 2; +pub const NETSVC_MRKNG_LVL_L3L2_BK: u32 = 3; +pub const SAE_ASSOCID_ANY: u32 = 0; +pub const SAE_CONNID_ANY: u32 = 0; +pub const CONNECT_RESUME_ON_READ_WRITE: u32 = 1; +pub const CONNECT_DATA_IDEMPOTENT: u32 = 2; +pub const CONNECT_DATA_AUTHENTICATED: u32 = 4; +pub const SONPX_SETOPTSHUT: u32 = 1; +pub const SOL_SOCKET: u32 = 65535; +pub const AF_UNSPEC: u32 = 0; +pub const AF_UNIX: u32 = 1; +pub const AF_LOCAL: u32 = 1; +pub const AF_INET: u32 = 2; +pub const AF_IMPLINK: u32 = 3; +pub const AF_PUP: u32 = 4; +pub const AF_CHAOS: u32 = 5; +pub const AF_NS: u32 = 6; +pub const AF_ISO: u32 = 7; +pub const AF_OSI: u32 = 7; +pub const AF_ECMA: u32 = 8; +pub const AF_DATAKIT: u32 = 9; +pub const AF_CCITT: u32 = 10; +pub const AF_SNA: u32 = 11; +pub const AF_DECnet: u32 = 12; +pub const AF_DLI: u32 = 13; +pub const AF_LAT: u32 = 14; +pub const AF_HYLINK: u32 = 15; +pub const AF_APPLETALK: u32 = 16; +pub const AF_ROUTE: u32 = 17; +pub const AF_LINK: u32 = 18; +pub const pseudo_AF_XTP: u32 = 19; +pub const AF_COIP: u32 = 20; +pub const AF_CNT: u32 = 21; +pub const pseudo_AF_RTIP: u32 = 22; +pub const AF_IPX: u32 = 23; +pub const AF_SIP: u32 = 24; +pub const pseudo_AF_PIP: u32 = 25; +pub const AF_NDRV: u32 = 27; +pub const AF_ISDN: u32 = 28; +pub const AF_E164: u32 = 28; +pub const pseudo_AF_KEY: u32 = 29; +pub const AF_INET6: u32 = 30; +pub const AF_NATM: u32 = 31; +pub const AF_SYSTEM: u32 = 32; +pub const AF_NETBIOS: u32 = 33; +pub const AF_PPP: u32 = 34; +pub const pseudo_AF_HDRCMPLT: u32 = 35; +pub const AF_AFP: u32 = 36; +pub const AF_IEEE80211: u32 = 37; +pub const AF_UTUN: u32 = 38; +pub const AF_MULTIPATH: u32 = 39; +pub const AF_VSOCK: u32 = 40; +pub const AF_MAX: u32 = 41; +pub const SOCK_MAXADDRLEN: u32 = 255; +pub const _SS_MAXSIZE: u32 = 128; +pub const PF_UNSPEC: u32 = 0; +pub const PF_LOCAL: u32 = 1; +pub const PF_UNIX: u32 = 1; +pub const PF_INET: u32 = 2; +pub const PF_IMPLINK: u32 = 3; +pub const PF_PUP: u32 = 4; +pub const PF_CHAOS: u32 = 5; +pub const PF_NS: u32 = 6; +pub const PF_ISO: u32 = 7; +pub const PF_OSI: u32 = 7; +pub const PF_ECMA: u32 = 8; +pub const PF_DATAKIT: u32 = 9; +pub const PF_CCITT: u32 = 10; +pub const PF_SNA: u32 = 11; +pub const PF_DECnet: u32 = 12; +pub const PF_DLI: u32 = 13; +pub const PF_LAT: u32 = 14; +pub const PF_HYLINK: u32 = 15; +pub const PF_APPLETALK: u32 = 16; +pub const PF_ROUTE: u32 = 17; +pub const PF_LINK: u32 = 18; +pub const PF_XTP: u32 = 19; +pub const PF_COIP: u32 = 20; +pub const PF_CNT: u32 = 21; +pub const PF_SIP: u32 = 24; +pub const PF_IPX: u32 = 23; +pub const PF_RTIP: u32 = 22; +pub const PF_PIP: u32 = 25; +pub const PF_NDRV: u32 = 27; +pub const PF_ISDN: u32 = 28; +pub const PF_KEY: u32 = 29; +pub const PF_INET6: u32 = 30; +pub const PF_NATM: u32 = 31; +pub const PF_SYSTEM: u32 = 32; +pub const PF_NETBIOS: u32 = 33; +pub const PF_PPP: u32 = 34; +pub const PF_AFP: u32 = 36; +pub const PF_UTUN: u32 = 38; +pub const PF_MULTIPATH: u32 = 39; +pub const PF_VSOCK: u32 = 40; +pub const PF_MAX: u32 = 41; +pub const NET_MAXID: u32 = 41; +pub const NET_RT_DUMP: u32 = 1; +pub const NET_RT_FLAGS: u32 = 2; +pub const NET_RT_IFLIST: u32 = 3; +pub const NET_RT_STAT: u32 = 4; +pub const NET_RT_TRASH: u32 = 5; +pub const NET_RT_IFLIST2: u32 = 6; +pub const NET_RT_DUMP2: u32 = 7; +pub const NET_RT_DUMPX: u32 = 8; +pub const NET_RT_DUMPX_FLAGS: u32 = 9; +pub const NET_RT_FLAGS_PRIV: u32 = 10; +pub const NET_RT_MAXID: u32 = 11; +pub const SO_STATISTICS_EVENT_ENTER_CELLFALLBACK: u32 = 1; +pub const SO_STATISTICS_EVENT_EXIT_CELLFALLBACK: u32 = 2; +pub const SO_STATISTICS_EVENT_RESERVED_1: u32 = 4; +pub const SO_STATISTICS_EVENT_RESERVED_2: u32 = 8; +pub const SOMAXCONN: u32 = 128; +pub const MSG_OOB: u32 = 1; +pub const MSG_PEEK: u32 = 2; +pub const MSG_DONTROUTE: u32 = 4; +pub const MSG_EOR: u32 = 8; +pub const MSG_TRUNC: u32 = 16; +pub const MSG_CTRUNC: u32 = 32; +pub const MSG_WAITALL: u32 = 64; +pub const MSG_DONTWAIT: u32 = 128; +pub const MSG_EOF: u32 = 256; +pub const MSG_WAITSTREAM: u32 = 512; +pub const MSG_FLUSH: u32 = 1024; +pub const MSG_HOLD: u32 = 2048; +pub const MSG_SEND: u32 = 4096; +pub const MSG_HAVEMORE: u32 = 8192; +pub const MSG_RCVMORE: u32 = 16384; +pub const MSG_NEEDSA: u32 = 65536; +pub const MSG_NOSIGNAL: u32 = 524288; +pub const SCM_RIGHTS: u32 = 1; +pub const SCM_TIMESTAMP: u32 = 2; +pub const SCM_CREDS: u32 = 3; +pub const SCM_TIMESTAMP_MONOTONIC: u32 = 4; +pub const SCM_TIMESTAMP_CONTINUOUS: u32 = 7; +pub const SCM_MPKL_SEND_INFO: u32 = 8; +pub const SCM_MPKL_RECV_INFO: u32 = 9; +pub const SHUT_RD: u32 = 0; +pub const SHUT_WR: u32 = 1; +pub const SHUT_RDWR: u32 = 2; +pub const CIF_CONNECTING: u32 = 1; +pub const CIF_CONNECTED: u32 = 2; +pub const CIF_DISCONNECTING: u32 = 4; +pub const CIF_DISCONNECTED: u32 = 8; +pub const CIF_BOUND_IF: u32 = 16; +pub const CIF_BOUND_IP: u32 = 32; +pub const CIF_BOUND_PORT: u32 = 64; +pub const CIF_PREFERRED: u32 = 128; +pub const CIF_MP_CAPABLE: u32 = 256; +pub const CIF_MP_READY: u32 = 512; +pub const CIF_MP_DEGRADED: u32 = 1024; +pub const CIF_MP_ACTIVE: u32 = 2048; +pub const CIAUX_TCP: u32 = 1; +pub const CIAUX_MPTCP: u32 = 2; +pub const IPPROTO_IP: u32 = 0; +pub const IPPROTO_HOPOPTS: u32 = 0; +pub const IPPROTO_ICMP: u32 = 1; +pub const IPPROTO_IGMP: u32 = 2; +pub const IPPROTO_GGP: u32 = 3; +pub const IPPROTO_IPV4: u32 = 4; +pub const IPPROTO_IPIP: u32 = 4; +pub const IPPROTO_TCP: u32 = 6; +pub const IPPROTO_ST: u32 = 7; +pub const IPPROTO_EGP: u32 = 8; +pub const IPPROTO_PIGP: u32 = 9; +pub const IPPROTO_RCCMON: u32 = 10; +pub const IPPROTO_NVPII: u32 = 11; +pub const IPPROTO_PUP: u32 = 12; +pub const IPPROTO_ARGUS: u32 = 13; +pub const IPPROTO_EMCON: u32 = 14; +pub const IPPROTO_XNET: u32 = 15; +pub const IPPROTO_CHAOS: u32 = 16; +pub const IPPROTO_UDP: u32 = 17; +pub const IPPROTO_MUX: u32 = 18; +pub const IPPROTO_MEAS: u32 = 19; +pub const IPPROTO_HMP: u32 = 20; +pub const IPPROTO_PRM: u32 = 21; +pub const IPPROTO_IDP: u32 = 22; +pub const IPPROTO_TRUNK1: u32 = 23; +pub const IPPROTO_TRUNK2: u32 = 24; +pub const IPPROTO_LEAF1: u32 = 25; +pub const IPPROTO_LEAF2: u32 = 26; +pub const IPPROTO_RDP: u32 = 27; +pub const IPPROTO_IRTP: u32 = 28; +pub const IPPROTO_TP: u32 = 29; +pub const IPPROTO_BLT: u32 = 30; +pub const IPPROTO_NSP: u32 = 31; +pub const IPPROTO_INP: u32 = 32; +pub const IPPROTO_SEP: u32 = 33; +pub const IPPROTO_3PC: u32 = 34; +pub const IPPROTO_IDPR: u32 = 35; +pub const IPPROTO_XTP: u32 = 36; +pub const IPPROTO_DDP: u32 = 37; +pub const IPPROTO_CMTP: u32 = 38; +pub const IPPROTO_TPXX: u32 = 39; +pub const IPPROTO_IL: u32 = 40; +pub const IPPROTO_IPV6: u32 = 41; +pub const IPPROTO_SDRP: u32 = 42; +pub const IPPROTO_ROUTING: u32 = 43; +pub const IPPROTO_FRAGMENT: u32 = 44; +pub const IPPROTO_IDRP: u32 = 45; +pub const IPPROTO_RSVP: u32 = 46; +pub const IPPROTO_GRE: u32 = 47; +pub const IPPROTO_MHRP: u32 = 48; +pub const IPPROTO_BHA: u32 = 49; +pub const IPPROTO_ESP: u32 = 50; +pub const IPPROTO_AH: u32 = 51; +pub const IPPROTO_INLSP: u32 = 52; +pub const IPPROTO_SWIPE: u32 = 53; +pub const IPPROTO_NHRP: u32 = 54; +pub const IPPROTO_ICMPV6: u32 = 58; +pub const IPPROTO_NONE: u32 = 59; +pub const IPPROTO_DSTOPTS: u32 = 60; +pub const IPPROTO_AHIP: u32 = 61; +pub const IPPROTO_CFTP: u32 = 62; +pub const IPPROTO_HELLO: u32 = 63; +pub const IPPROTO_SATEXPAK: u32 = 64; +pub const IPPROTO_KRYPTOLAN: u32 = 65; +pub const IPPROTO_RVD: u32 = 66; +pub const IPPROTO_IPPC: u32 = 67; +pub const IPPROTO_ADFS: u32 = 68; +pub const IPPROTO_SATMON: u32 = 69; +pub const IPPROTO_VISA: u32 = 70; +pub const IPPROTO_IPCV: u32 = 71; +pub const IPPROTO_CPNX: u32 = 72; +pub const IPPROTO_CPHB: u32 = 73; +pub const IPPROTO_WSN: u32 = 74; +pub const IPPROTO_PVP: u32 = 75; +pub const IPPROTO_BRSATMON: u32 = 76; +pub const IPPROTO_ND: u32 = 77; +pub const IPPROTO_WBMON: u32 = 78; +pub const IPPROTO_WBEXPAK: u32 = 79; +pub const IPPROTO_EON: u32 = 80; +pub const IPPROTO_VMTP: u32 = 81; +pub const IPPROTO_SVMTP: u32 = 82; +pub const IPPROTO_VINES: u32 = 83; +pub const IPPROTO_TTP: u32 = 84; +pub const IPPROTO_IGP: u32 = 85; +pub const IPPROTO_DGP: u32 = 86; +pub const IPPROTO_TCF: u32 = 87; +pub const IPPROTO_IGRP: u32 = 88; +pub const IPPROTO_OSPFIGP: u32 = 89; +pub const IPPROTO_SRPC: u32 = 90; +pub const IPPROTO_LARP: u32 = 91; +pub const IPPROTO_MTP: u32 = 92; +pub const IPPROTO_AX25: u32 = 93; +pub const IPPROTO_IPEIP: u32 = 94; +pub const IPPROTO_MICP: u32 = 95; +pub const IPPROTO_SCCSP: u32 = 96; +pub const IPPROTO_ETHERIP: u32 = 97; +pub const IPPROTO_ENCAP: u32 = 98; +pub const IPPROTO_APES: u32 = 99; +pub const IPPROTO_GMTP: u32 = 100; +pub const IPPROTO_PIM: u32 = 103; +pub const IPPROTO_IPCOMP: u32 = 108; +pub const IPPROTO_PGM: u32 = 113; +pub const IPPROTO_SCTP: u32 = 132; +pub const IPPROTO_QUIC: u32 = 253; +pub const IPPROTO_DIVERT: u32 = 254; +pub const IPPROTO_RAW: u32 = 255; +pub const IPPROTO_MAX: u32 = 256; +pub const IPPROTO_DONE: u32 = 257; +pub const __DARWIN_IPPORT_RESERVED: u32 = 1024; +pub const IPPORT_RESERVED: u32 = 1024; +pub const IPPORT_USERRESERVED: u32 = 5000; +pub const IPPORT_HIFIRSTAUTO: u32 = 49152; +pub const IPPORT_HILASTAUTO: u32 = 65535; +pub const IPPORT_RESERVEDSTART: u32 = 600; +pub const IN_CLASSA_NET: u32 = 4278190080; +pub const IN_CLASSA_NSHIFT: u32 = 24; +pub const IN_CLASSA_HOST: u32 = 16777215; +pub const IN_CLASSA_MAX: u32 = 128; +pub const IN_CLASSB_NET: u32 = 4294901760; +pub const IN_CLASSB_NSHIFT: u32 = 16; +pub const IN_CLASSB_HOST: u32 = 65535; +pub const IN_CLASSB_MAX: u32 = 65536; +pub const IN_CLASSC_NET: u32 = 4294967040; +pub const IN_CLASSC_NSHIFT: u32 = 8; +pub const IN_CLASSC_HOST: u32 = 255; +pub const IN_CLASSD_NET: u32 = 4026531840; +pub const IN_CLASSD_NSHIFT: u32 = 28; +pub const IN_CLASSD_HOST: u32 = 268435455; +pub const INADDR_NONE: u32 = 4294967295; +pub const IN_LOOPBACKNET: u32 = 127; +pub const INET_ADDRSTRLEN: u32 = 16; +pub const IP_OPTIONS: u32 = 1; +pub const IP_HDRINCL: u32 = 2; +pub const IP_TOS: u32 = 3; +pub const IP_TTL: u32 = 4; +pub const IP_RECVOPTS: u32 = 5; +pub const IP_RECVRETOPTS: u32 = 6; +pub const IP_RECVDSTADDR: u32 = 7; +pub const IP_RETOPTS: u32 = 8; +pub const IP_MULTICAST_IF: u32 = 9; +pub const IP_MULTICAST_TTL: u32 = 10; +pub const IP_MULTICAST_LOOP: u32 = 11; +pub const IP_ADD_MEMBERSHIP: u32 = 12; +pub const IP_DROP_MEMBERSHIP: u32 = 13; +pub const IP_MULTICAST_VIF: u32 = 14; +pub const IP_RSVP_ON: u32 = 15; +pub const IP_RSVP_OFF: u32 = 16; +pub const IP_RSVP_VIF_ON: u32 = 17; +pub const IP_RSVP_VIF_OFF: u32 = 18; +pub const IP_PORTRANGE: u32 = 19; +pub const IP_RECVIF: u32 = 20; +pub const IP_IPSEC_POLICY: u32 = 21; +pub const IP_FAITH: u32 = 22; +pub const IP_STRIPHDR: u32 = 23; +pub const IP_RECVTTL: u32 = 24; +pub const IP_BOUND_IF: u32 = 25; +pub const IP_PKTINFO: u32 = 26; +pub const IP_RECVPKTINFO: u32 = 26; +pub const IP_RECVTOS: u32 = 27; +pub const IP_DONTFRAG: u32 = 28; +pub const IP_FW_ADD: u32 = 40; +pub const IP_FW_DEL: u32 = 41; +pub const IP_FW_FLUSH: u32 = 42; +pub const IP_FW_ZERO: u32 = 43; +pub const IP_FW_GET: u32 = 44; +pub const IP_FW_RESETLOG: u32 = 45; +pub const IP_OLD_FW_ADD: u32 = 50; +pub const IP_OLD_FW_DEL: u32 = 51; +pub const IP_OLD_FW_FLUSH: u32 = 52; +pub const IP_OLD_FW_ZERO: u32 = 53; +pub const IP_OLD_FW_GET: u32 = 54; +pub const IP_NAT__XXX: u32 = 55; +pub const IP_OLD_FW_RESETLOG: u32 = 56; +pub const IP_DUMMYNET_CONFIGURE: u32 = 60; +pub const IP_DUMMYNET_DEL: u32 = 61; +pub const IP_DUMMYNET_FLUSH: u32 = 62; +pub const IP_DUMMYNET_GET: u32 = 64; +pub const IP_TRAFFIC_MGT_BACKGROUND: u32 = 65; +pub const IP_MULTICAST_IFINDEX: u32 = 66; +pub const IP_ADD_SOURCE_MEMBERSHIP: u32 = 70; +pub const IP_DROP_SOURCE_MEMBERSHIP: u32 = 71; +pub const IP_BLOCK_SOURCE: u32 = 72; +pub const IP_UNBLOCK_SOURCE: u32 = 73; +pub const IP_MSFILTER: u32 = 74; +pub const MCAST_JOIN_GROUP: u32 = 80; +pub const MCAST_LEAVE_GROUP: u32 = 81; +pub const MCAST_JOIN_SOURCE_GROUP: u32 = 82; +pub const MCAST_LEAVE_SOURCE_GROUP: u32 = 83; +pub const MCAST_BLOCK_SOURCE: u32 = 84; +pub const MCAST_UNBLOCK_SOURCE: u32 = 85; +pub const IP_NO_IFT_CELLULAR: u32 = 6969; +pub const IP_NO_IFT_PDP: u32 = 6969; +pub const IP_OUT_IF: u32 = 9696; +pub const IP_DEFAULT_MULTICAST_TTL: u32 = 1; +pub const IP_DEFAULT_MULTICAST_LOOP: u32 = 1; +pub const IP_MIN_MEMBERSHIPS: u32 = 31; +pub const IP_MAX_MEMBERSHIPS: u32 = 4095; +pub const IP_MAX_GROUP_SRC_FILTER: u32 = 512; +pub const IP_MAX_SOCK_SRC_FILTER: u32 = 128; +pub const IP_MAX_SOCK_MUTE_FILTER: u32 = 128; +pub const MCAST_UNDEFINED: u32 = 0; +pub const MCAST_INCLUDE: u32 = 1; +pub const MCAST_EXCLUDE: u32 = 2; +pub const IP_PORTRANGE_DEFAULT: u32 = 0; +pub const IP_PORTRANGE_HIGH: u32 = 1; +pub const IP_PORTRANGE_LOW: u32 = 2; +pub const IPPROTO_MAXID: u32 = 52; +pub const IPCTL_FORWARDING: u32 = 1; +pub const IPCTL_SENDREDIRECTS: u32 = 2; +pub const IPCTL_DEFTTL: u32 = 3; +pub const IPCTL_RTEXPIRE: u32 = 5; +pub const IPCTL_RTMINEXPIRE: u32 = 6; +pub const IPCTL_RTMAXCACHE: u32 = 7; +pub const IPCTL_SOURCEROUTE: u32 = 8; +pub const IPCTL_DIRECTEDBROADCAST: u32 = 9; +pub const IPCTL_INTRQMAXLEN: u32 = 10; +pub const IPCTL_INTRQDROPS: u32 = 11; +pub const IPCTL_STATS: u32 = 12; +pub const IPCTL_ACCEPTSOURCEROUTE: u32 = 13; +pub const IPCTL_FASTFORWARDING: u32 = 14; +pub const IPCTL_KEEPFAITH: u32 = 15; +pub const IPCTL_GIF_TTL: u32 = 16; +pub const IPCTL_MAXID: u32 = 17; +pub const __KAME_VERSION: &[u8; 18] = b"2009/apple-darwin\0"; +pub const IPV6PORT_RESERVED: u32 = 1024; +pub const IPV6PORT_ANONMIN: u32 = 49152; +pub const IPV6PORT_ANONMAX: u32 = 65535; +pub const IPV6PORT_RESERVEDMIN: u32 = 600; +pub const IPV6PORT_RESERVEDMAX: u32 = 1023; +pub const INET6_ADDRSTRLEN: u32 = 46; +pub const __IPV6_ADDR_SCOPE_NODELOCAL: u32 = 1; +pub const __IPV6_ADDR_SCOPE_INTFACELOCAL: u32 = 1; +pub const __IPV6_ADDR_SCOPE_LINKLOCAL: u32 = 2; +pub const __IPV6_ADDR_SCOPE_SITELOCAL: u32 = 5; +pub const __IPV6_ADDR_SCOPE_ORGLOCAL: u32 = 8; +pub const __IPV6_ADDR_SCOPE_GLOBAL: u32 = 14; +pub const IPV6_ADDR_MC_FLAGS_TRANSIENT: u32 = 16; +pub const IPV6_ADDR_MC_FLAGS_PREFIX: u32 = 32; +pub const IPV6_ADDR_MC_FLAGS_UNICAST_BASED: u32 = 48; +pub const IPV6_SOCKOPT_RESERVED1: u32 = 3; +pub const IPV6_UNICAST_HOPS: u32 = 4; +pub const IPV6_MULTICAST_IF: u32 = 9; +pub const IPV6_MULTICAST_HOPS: u32 = 10; +pub const IPV6_MULTICAST_LOOP: u32 = 11; +pub const IPV6_JOIN_GROUP: u32 = 12; +pub const IPV6_LEAVE_GROUP: u32 = 13; +pub const IPV6_PORTRANGE: u32 = 14; +pub const ICMP6_FILTER: u32 = 18; +pub const IPV6_2292PKTINFO: u32 = 19; +pub const IPV6_2292HOPLIMIT: u32 = 20; +pub const IPV6_2292NEXTHOP: u32 = 21; +pub const IPV6_2292HOPOPTS: u32 = 22; +pub const IPV6_2292DSTOPTS: u32 = 23; +pub const IPV6_2292RTHDR: u32 = 24; +pub const IPV6_2292PKTOPTIONS: u32 = 25; +pub const IPV6_CHECKSUM: u32 = 26; +pub const IPV6_V6ONLY: u32 = 27; +pub const IPV6_BINDV6ONLY: u32 = 27; +pub const IPV6_IPSEC_POLICY: u32 = 28; +pub const IPV6_FAITH: u32 = 29; +pub const IPV6_FW_ADD: u32 = 30; +pub const IPV6_FW_DEL: u32 = 31; +pub const IPV6_FW_FLUSH: u32 = 32; +pub const IPV6_FW_ZERO: u32 = 33; +pub const IPV6_FW_GET: u32 = 34; +pub const IPV6_RECVTCLASS: u32 = 35; +pub const IPV6_TCLASS: u32 = 36; +pub const IPV6_BOUND_IF: u32 = 125; +pub const IPV6_NO_IFT_CELLULAR: u32 = 6969; +pub const IPV6_OUT_IF: u32 = 9696; +pub const IPV6_RTHDR_LOOSE: u32 = 0; +pub const IPV6_RTHDR_STRICT: u32 = 1; +pub const IPV6_RTHDR_TYPE_0: u32 = 0; +pub const IPV6_DEFAULT_MULTICAST_HOPS: u32 = 1; +pub const IPV6_DEFAULT_MULTICAST_LOOP: u32 = 1; +pub const IPV6_MIN_MEMBERSHIPS: u32 = 31; +pub const IPV6_MAX_MEMBERSHIPS: u32 = 4095; +pub const IPV6_MAX_GROUP_SRC_FILTER: u32 = 512; +pub const IPV6_MAX_SOCK_SRC_FILTER: u32 = 128; +pub const IPV6_PORTRANGE_DEFAULT: u32 = 0; +pub const IPV6_PORTRANGE_HIGH: u32 = 1; +pub const IPV6_PORTRANGE_LOW: u32 = 2; +pub const IPV6PROTO_MAXID: u32 = 104; +pub const IPV6CTL_FORWARDING: u32 = 1; +pub const IPV6CTL_SENDREDIRECTS: u32 = 2; +pub const IPV6CTL_DEFHLIM: u32 = 3; +pub const IPV6CTL_FORWSRCRT: u32 = 5; +pub const IPV6CTL_STATS: u32 = 6; +pub const IPV6CTL_MRTSTATS: u32 = 7; +pub const IPV6CTL_MRTPROTO: u32 = 8; +pub const IPV6CTL_MAXFRAGPACKETS: u32 = 9; +pub const IPV6CTL_SOURCECHECK: u32 = 10; +pub const IPV6CTL_SOURCECHECK_LOGINT: u32 = 11; +pub const IPV6CTL_ACCEPT_RTADV: u32 = 12; +pub const IPV6CTL_KEEPFAITH: u32 = 13; +pub const IPV6CTL_LOG_INTERVAL: u32 = 14; +pub const IPV6CTL_HDRNESTLIMIT: u32 = 15; +pub const IPV6CTL_DAD_COUNT: u32 = 16; +pub const IPV6CTL_AUTO_FLOWLABEL: u32 = 17; +pub const IPV6CTL_DEFMCASTHLIM: u32 = 18; +pub const IPV6CTL_GIF_HLIM: u32 = 19; +pub const IPV6CTL_KAME_VERSION: u32 = 20; +pub const IPV6CTL_USE_DEPRECATED: u32 = 21; +pub const IPV6CTL_RR_PRUNE: u32 = 22; +pub const IPV6CTL_V6ONLY: u32 = 24; +pub const IPV6CTL_RTEXPIRE: u32 = 25; +pub const IPV6CTL_RTMINEXPIRE: u32 = 26; +pub const IPV6CTL_RTMAXCACHE: u32 = 27; +pub const IPV6CTL_USETEMPADDR: u32 = 32; +pub const IPV6CTL_TEMPPLTIME: u32 = 33; +pub const IPV6CTL_TEMPVLTIME: u32 = 34; +pub const IPV6CTL_AUTO_LINKLOCAL: u32 = 35; +pub const IPV6CTL_RIP6STATS: u32 = 36; +pub const IPV6CTL_PREFER_TEMPADDR: u32 = 37; +pub const IPV6CTL_ADDRCTLPOLICY: u32 = 38; +pub const IPV6CTL_USE_DEFAULTZONE: u32 = 39; +pub const IPV6CTL_MAXFRAGS: u32 = 41; +pub const IPV6CTL_MCAST_PMTU: u32 = 44; +pub const IPV6CTL_NEIGHBORGCTHRESH: u32 = 46; +pub const IPV6CTL_MAXIFPREFIXES: u32 = 47; +pub const IPV6CTL_MAXIFDEFROUTERS: u32 = 48; +pub const IPV6CTL_MAXDYNROUTES: u32 = 49; +pub const ICMPV6CTL_ND6_ONLINKNSRFC4861: u32 = 50; +pub const IPV6CTL_ULA_USETEMPADDR: u32 = 51; +pub const IPV6CTL_MAXID: u32 = 51; +pub const _DSCP_DF: u32 = 0; +pub const _DSCP_CS0: u32 = 0; +pub const _DSCP_CS1: u32 = 8; +pub const _DSCP_CS2: u32 = 16; +pub const _DSCP_CS3: u32 = 24; +pub const _DSCP_CS4: u32 = 32; +pub const _DSCP_CS5: u32 = 40; +pub const _DSCP_CS6: u32 = 48; +pub const _DSCP_CS7: u32 = 56; +pub const _DSCP_EF: u32 = 46; +pub const _DSCP_VA: u32 = 44; +pub const _DSCP_AF11: u32 = 10; +pub const _DSCP_AF12: u32 = 12; +pub const _DSCP_AF13: u32 = 14; +pub const _DSCP_AF21: u32 = 18; +pub const _DSCP_AF22: u32 = 20; +pub const _DSCP_AF23: u32 = 22; +pub const _DSCP_AF31: u32 = 26; +pub const _DSCP_AF32: u32 = 28; +pub const _DSCP_AF33: u32 = 30; +pub const _DSCP_AF41: u32 = 34; +pub const _DSCP_AF42: u32 = 36; +pub const _DSCP_AF43: u32 = 38; +pub const _DSCP_52: u32 = 52; +pub const _MAX_DSCP: u32 = 63; +pub const ITIMER_REAL: u32 = 0; +pub const ITIMER_VIRTUAL: u32 = 1; +pub const ITIMER_PROF: u32 = 2; +pub const DST_NONE: u32 = 0; +pub const DST_USA: u32 = 1; +pub const DST_AUST: u32 = 2; +pub const DST_WET: u32 = 3; +pub const DST_MET: u32 = 4; +pub const DST_EET: u32 = 5; +pub const DST_CAN: u32 = 6; +pub const __DARWIN_WCHAR_MIN: i32 = -2147483648; +pub const _FORTIFY_SOURCE: u32 = 2; +pub const TIME_UTC: u32 = 1; +pub const RTM_RTTUNIT: u32 = 1000000; +pub const RTF_UP: u32 = 1; +pub const RTF_GATEWAY: u32 = 2; +pub const RTF_HOST: u32 = 4; +pub const RTF_REJECT: u32 = 8; +pub const RTF_DYNAMIC: u32 = 16; +pub const RTF_MODIFIED: u32 = 32; +pub const RTF_DONE: u32 = 64; +pub const RTF_DELCLONE: u32 = 128; +pub const RTF_CLONING: u32 = 256; +pub const RTF_XRESOLVE: u32 = 512; +pub const RTF_LLINFO: u32 = 1024; +pub const RTF_LLDATA: u32 = 1024; +pub const RTF_STATIC: u32 = 2048; +pub const RTF_BLACKHOLE: u32 = 4096; +pub const RTF_NOIFREF: u32 = 8192; +pub const RTF_PROTO2: u32 = 16384; +pub const RTF_PROTO1: u32 = 32768; +pub const RTF_PRCLONING: u32 = 65536; +pub const RTF_WASCLONED: u32 = 131072; +pub const RTF_PROTO3: u32 = 262144; +pub const RTF_PINNED: u32 = 1048576; +pub const RTF_LOCAL: u32 = 2097152; +pub const RTF_BROADCAST: u32 = 4194304; +pub const RTF_MULTICAST: u32 = 8388608; +pub const RTF_IFSCOPE: u32 = 16777216; +pub const RTF_CONDEMNED: u32 = 33554432; +pub const RTF_IFREF: u32 = 67108864; +pub const RTF_PROXY: u32 = 134217728; +pub const RTF_ROUTER: u32 = 268435456; +pub const RTF_DEAD: u32 = 536870912; +pub const RTF_GLOBAL: u32 = 1073741824; +pub const RTPRF_OURS: u32 = 262144; +pub const RTF_BITS : & [u8 ; 223] = b"\x10\x01UP\x02GATEWAY\x03HOST\x04REJECT\x05DYNAMIC\x06MODIFIED\x07DONE\x08DELCLONE\tCLONING\nXRESOLVE\x0BLLINFO\x0CSTATIC\rBLACKHOLE\x0ENOIFREF\x0FPROTO2\x10PROTO1\x11PRCLONING\x12WASCLONED\x13PROTO3\x15PINNED\x16LOCAL\x17BROADCAST\x18MULTICAST\x19IFSCOPE\x1ACONDEMNED\x1BIFREF\x1CPROXY\x1DROUTER\x1FGLOBAL\0" ; +pub const RTM_VERSION: u32 = 5; +pub const RTM_ADD: u32 = 1; +pub const RTM_DELETE: u32 = 2; +pub const RTM_CHANGE: u32 = 3; +pub const RTM_GET: u32 = 4; +pub const RTM_LOSING: u32 = 5; +pub const RTM_REDIRECT: u32 = 6; +pub const RTM_MISS: u32 = 7; +pub const RTM_LOCK: u32 = 8; +pub const RTM_OLDADD: u32 = 9; +pub const RTM_OLDDEL: u32 = 10; +pub const RTM_RESOLVE: u32 = 11; +pub const RTM_NEWADDR: u32 = 12; +pub const RTM_DELADDR: u32 = 13; +pub const RTM_IFINFO: u32 = 14; +pub const RTM_NEWMADDR: u32 = 15; +pub const RTM_DELMADDR: u32 = 16; +pub const RTM_GET_SILENT: u32 = 17; +pub const RTM_IFINFO2: u32 = 18; +pub const RTM_NEWMADDR2: u32 = 19; +pub const RTM_GET2: u32 = 20; +pub const RTM_GET_EXT: u32 = 21; +pub const RTV_MTU: u32 = 1; +pub const RTV_HOPCOUNT: u32 = 2; +pub const RTV_EXPIRE: u32 = 4; +pub const RTV_RPIPE: u32 = 8; +pub const RTV_SPIPE: u32 = 16; +pub const RTV_SSTHRESH: u32 = 32; +pub const RTV_RTT: u32 = 64; +pub const RTV_RTTVAR: u32 = 128; +pub const RTV_REFRESH_HOST: u32 = 256; +pub const RTA_DST: u32 = 1; +pub const RTA_GATEWAY: u32 = 2; +pub const RTA_NETMASK: u32 = 4; +pub const RTA_GENMASK: u32 = 8; +pub const RTA_IFP: u32 = 16; +pub const RTA_IFA: u32 = 32; +pub const RTA_AUTHOR: u32 = 64; +pub const RTA_BRD: u32 = 128; +pub const RTAX_DST: u32 = 0; +pub const RTAX_GATEWAY: u32 = 1; +pub const RTAX_NETMASK: u32 = 2; +pub const RTAX_GENMASK: u32 = 3; +pub const RTAX_IFP: u32 = 4; +pub const RTAX_IFA: u32 = 5; +pub const RTAX_AUTHOR: u32 = 6; +pub const RTAX_BRD: u32 = 7; +pub const RTAX_MAX: u32 = 8; +pub const IFSCOPE_NONE: u32 = 0; +pub const APPLE_IF_FAM_LOOPBACK: u32 = 1; +pub const APPLE_IF_FAM_ETHERNET: u32 = 2; +pub const APPLE_IF_FAM_SLIP: u32 = 3; +pub const APPLE_IF_FAM_TUN: u32 = 4; +pub const APPLE_IF_FAM_VLAN: u32 = 5; +pub const APPLE_IF_FAM_PPP: u32 = 6; +pub const APPLE_IF_FAM_PVC: u32 = 7; +pub const APPLE_IF_FAM_DISC: u32 = 8; +pub const APPLE_IF_FAM_MDECAP: u32 = 9; +pub const APPLE_IF_FAM_GIF: u32 = 10; +pub const APPLE_IF_FAM_FAITH: u32 = 11; +pub const APPLE_IF_FAM_STF: u32 = 12; +pub const APPLE_IF_FAM_FIREWIRE: u32 = 13; +pub const APPLE_IF_FAM_BOND: u32 = 14; +pub const APPLE_IF_FAM_CELLULAR: u32 = 15; +pub const APPLE_IF_FAM_6LOWPAN: u32 = 16; +pub const APPLE_IF_FAM_UTUN: u32 = 17; +pub const APPLE_IF_FAM_IPSEC: u32 = 18; +pub const IF_MINMTU: u32 = 72; +pub const IF_MAXMTU: u32 = 65535; +pub const IFNAMSIZ: u32 = 16; +pub const IF_NETEM_PARAMS_PSCALE: u32 = 100000; +pub const IF_VAR_H_HAS_IFNET_STATS_PER_FLOW: u32 = 1; +pub const IF_CELLULAR_STATUS_REPORT_VERSION_1: u32 = 1; +pub const IF_WIFI_STATUS_REPORT_VERSION_1: u32 = 1; +pub const IF_CELLULAR_STATUS_REPORT_CURRENT_VERSION: u32 = 1; +pub const IF_WIFI_STATUS_REPORT_CURRENT_VERSION: u32 = 1; +pub const IF_CELL_LINK_QUALITY_METRIC_VALID: u32 = 1; +pub const IF_CELL_UL_EFFECTIVE_BANDWIDTH_VALID: u32 = 2; +pub const IF_CELL_UL_MAX_BANDWIDTH_VALID: u32 = 4; +pub const IF_CELL_UL_MIN_LATENCY_VALID: u32 = 8; +pub const IF_CELL_UL_EFFECTIVE_LATENCY_VALID: u32 = 16; +pub const IF_CELL_UL_MAX_LATENCY_VALID: u32 = 32; +pub const IF_CELL_UL_RETXT_LEVEL_VALID: u32 = 64; +pub const IF_CELL_UL_BYTES_LOST_VALID: u32 = 128; +pub const IF_CELL_UL_MIN_QUEUE_SIZE_VALID: u32 = 256; +pub const IF_CELL_UL_AVG_QUEUE_SIZE_VALID: u32 = 512; +pub const IF_CELL_UL_MAX_QUEUE_SIZE_VALID: u32 = 1024; +pub const IF_CELL_DL_EFFECTIVE_BANDWIDTH_VALID: u32 = 2048; +pub const IF_CELL_DL_MAX_BANDWIDTH_VALID: u32 = 4096; +pub const IF_CELL_CONFIG_INACTIVITY_TIME_VALID: u32 = 8192; +pub const IF_CELL_CONFIG_BACKOFF_TIME_VALID: u32 = 16384; +pub const IF_CELL_UL_MSS_RECOMMENDED_VALID: u32 = 32768; +pub const IF_CELL_UL_RETXT_LEVEL_NONE: u32 = 1; +pub const IF_CELL_UL_RETXT_LEVEL_LOW: u32 = 2; +pub const IF_CELL_UL_RETXT_LEVEL_MEDIUM: u32 = 3; +pub const IF_CELL_UL_RETXT_LEVEL_HIGH: u32 = 4; +pub const IF_CELL_UL_MSS_RECOMMENDED_NONE: u32 = 0; +pub const IF_CELL_UL_MSS_RECOMMENDED_MEDIUM: u32 = 1; +pub const IF_CELL_UL_MSS_RECOMMENDED_LOW: u32 = 2; +pub const IF_WIFI_LINK_QUALITY_METRIC_VALID: u32 = 1; +pub const IF_WIFI_UL_EFFECTIVE_BANDWIDTH_VALID: u32 = 2; +pub const IF_WIFI_UL_MAX_BANDWIDTH_VALID: u32 = 4; +pub const IF_WIFI_UL_MIN_LATENCY_VALID: u32 = 8; +pub const IF_WIFI_UL_EFFECTIVE_LATENCY_VALID: u32 = 16; +pub const IF_WIFI_UL_MAX_LATENCY_VALID: u32 = 32; +pub const IF_WIFI_UL_RETXT_LEVEL_VALID: u32 = 64; +pub const IF_WIFI_UL_ERROR_RATE_VALID: u32 = 128; +pub const IF_WIFI_UL_BYTES_LOST_VALID: u32 = 256; +pub const IF_WIFI_DL_EFFECTIVE_BANDWIDTH_VALID: u32 = 512; +pub const IF_WIFI_DL_MAX_BANDWIDTH_VALID: u32 = 1024; +pub const IF_WIFI_DL_MIN_LATENCY_VALID: u32 = 2048; +pub const IF_WIFI_DL_EFFECTIVE_LATENCY_VALID: u32 = 4096; +pub const IF_WIFI_DL_MAX_LATENCY_VALID: u32 = 8192; +pub const IF_WIFI_DL_ERROR_RATE_VALID: u32 = 16384; +pub const IF_WIFI_CONFIG_FREQUENCY_VALID: u32 = 32768; +pub const IF_WIFI_CONFIG_MULTICAST_RATE_VALID: u32 = 65536; +pub const IF_WIFI_CONFIG_SCAN_COUNT_VALID: u32 = 131072; +pub const IF_WIFI_CONFIG_SCAN_DURATION_VALID: u32 = 262144; +pub const IF_WIFI_UL_RETXT_LEVEL_NONE: u32 = 1; +pub const IF_WIFI_UL_RETXT_LEVEL_LOW: u32 = 2; +pub const IF_WIFI_UL_RETXT_LEVEL_MEDIUM: u32 = 3; +pub const IF_WIFI_UL_RETXT_LEVEL_HIGH: u32 = 4; +pub const IF_WIFI_CONFIG_FREQUENCY_2_4_GHZ: u32 = 1; +pub const IF_WIFI_CONFIG_FREQUENCY_5_0_GHZ: u32 = 2; +pub const IF_INTERFACE_STATE_RRC_STATE_VALID: u32 = 1; +pub const IF_INTERFACE_STATE_LQM_STATE_VALID: u32 = 2; +pub const IF_INTERFACE_STATE_INTERFACE_AVAILABILITY_VALID: u32 = 4; +pub const IF_INTERFACE_STATE_RRC_STATE_IDLE: u32 = 0; +pub const IF_INTERFACE_STATE_RRC_STATE_CONNECTED: u32 = 1; +pub const IF_INTERFACE_STATE_INTERFACE_AVAILABLE: u32 = 0; +pub const IF_INTERFACE_STATE_INTERFACE_UNAVAILABLE: u32 = 1; +pub const IF_INTERFACE_ADVISORY_VERSION_1: u32 = 1; +pub const IF_INTERFACE_ADVISORY_VERSION_CURRENT: u32 = 1; +pub const IF_INTERFACE_ADVISORY_DIRECTION_TX: u32 = 1; +pub const IF_INTERFACE_ADVISORY_DIRECTION_RX: u32 = 2; +pub const IF_INTERFACE_ADVISORY_RATE_SUGGESTION_RAMP_UP: u32 = 2147483647; +pub const IF_INTERFACE_ADVISORY_RATE_SUGGESTION_RAMP_DOWN: i32 = -2147483648; +pub const IF_INTERFACE_ADVISORY_RATE_SUGGESTION_RAMP_NEUTRAL: u32 = 0; +pub const IF_HWASSIST_CSUM_IP: u32 = 1; +pub const IF_HWASSIST_CSUM_TCP: u32 = 2; +pub const IF_HWASSIST_CSUM_UDP: u32 = 4; +pub const IF_HWASSIST_CSUM_IP_FRAGS: u32 = 8; +pub const IF_HWASSIST_CSUM_FRAGMENT: u32 = 16; +pub const IF_HWASSIST_CSUM_TCPIPV6: u32 = 32; +pub const IF_HWASSIST_CSUM_UDPIPV6: u32 = 64; +pub const IF_HWASSIST_CSUM_FRAGMENT_IPV6: u32 = 128; +pub const IF_HWASSIST_CSUM_PARTIAL: u32 = 4096; +pub const IF_HWASSIST_CSUM_ZERO_INVERT: u32 = 8192; +pub const IF_HWASSIST_CSUM_MASK: u32 = 65535; +pub const IF_HWASSIST_VLAN_TAGGING: u32 = 65536; +pub const IF_HWASSIST_VLAN_MTU: u32 = 131072; +pub const IF_HWASSIST_TSO_V4: u32 = 2097152; +pub const IF_HWASSIST_TSO_V6: u32 = 4194304; +pub const IFXNAMSIZ: u32 = 24; +pub const IFNET_NETWORK_ID_LEN: u32 = 32; +pub const PF_MD5_DIGEST_LENGTH: u32 = 16; +pub const PF_GRE_PPTP_VARIANT: u32 = 1; +pub const PFTM_TCP_FIRST_PACKET_VAL: u32 = 120; +pub const PFTM_TCP_OPENING_VAL: u32 = 30; +pub const PFTM_TCP_ESTABLISHED_VAL: u32 = 86400; +pub const PFTM_TCP_CLOSING_VAL: u32 = 900; +pub const PFTM_TCP_FIN_WAIT_VAL: u32 = 45; +pub const PFTM_TCP_CLOSED_VAL: u32 = 90; +pub const PFTM_UDP_FIRST_PACKET_VAL: u32 = 60; +pub const PFTM_UDP_SINGLE_VAL: u32 = 30; +pub const PFTM_UDP_MULTIPLE_VAL: u32 = 60; +pub const PFTM_ICMP_FIRST_PACKET_VAL: u32 = 20; +pub const PFTM_ICMP_ERROR_REPLY_VAL: u32 = 10; +pub const PFTM_GREv1_FIRST_PACKET_VAL: u32 = 120; +pub const PFTM_GREv1_INITIATING_VAL: u32 = 30; +pub const PFTM_GREv1_ESTABLISHED_VAL: u32 = 1800; +pub const PFTM_ESP_FIRST_PACKET_VAL: u32 = 120; +pub const PFTM_ESP_INITIATING_VAL: u32 = 30; +pub const PFTM_ESP_ESTABLISHED_VAL: u32 = 900; +pub const PFTM_OTHER_FIRST_PACKET_VAL: u32 = 60; +pub const PFTM_OTHER_SINGLE_VAL: u32 = 30; +pub const PFTM_OTHER_MULTIPLE_VAL: u32 = 60; +pub const PFTM_FRAG_VAL: u32 = 30; +pub const PFTM_INTERVAL_VAL: u32 = 10; +pub const PFTM_SRC_NODE_VAL: u32 = 0; +pub const PFTM_TS_DIFF_VAL: u32 = 30; +pub const PF_POOL_IDMASK: u32 = 15; +pub const PF_POOL_TYPEMASK: u32 = 15; +pub const PF_POOL_STICKYADDR: u32 = 32; +pub const PF_WSCALE_FLAG: u32 = 128; +pub const PF_WSCALE_MASK: u32 = 15; +pub const PF_LOG: u32 = 1; +pub const PF_LOG_ALL: u32 = 2; +pub const PF_LOG_SOCKET_LOOKUP: u32 = 4; +pub const PF_TABLE_NAME_SIZE: u32 = 32; +pub const PFI_AFLAG_NETWORK: u32 = 1; +pub const PFI_AFLAG_BROADCAST: u32 = 2; +pub const PFI_AFLAG_PEER: u32 = 4; +pub const PFI_AFLAG_MODEMASK: u32 = 7; +pub const PFI_AFLAG_NOALIAS: u32 = 8; +pub const RTLABEL_LEN: u32 = 32; +pub const PF_OSFP_EXPANDED: u32 = 1; +pub const PF_OSFP_GENERIC: u32 = 2; +pub const PF_OSFP_NODETAIL: u32 = 4; +pub const PF_OSFP_LEN: u32 = 32; +pub const _FP_RESERVED_BIT: u32 = 1; +pub const _FP_UNUSED_BITS: u32 = 1; +pub const _FP_CLASS_BITS: u32 = 10; +pub const _FP_VERSION_BITS: u32 = 10; +pub const _FP_SUBTYPE_BITS: u32 = 10; +pub const PF_OSFP_WSIZE_MOD: u32 = 1; +pub const PF_OSFP_WSIZE_DC: u32 = 2; +pub const PF_OSFP_WSIZE_MSS: u32 = 4; +pub const PF_OSFP_WSIZE_MTU: u32 = 8; +pub const PF_OSFP_PSIZE_MOD: u32 = 16; +pub const PF_OSFP_PSIZE_DC: u32 = 32; +pub const PF_OSFP_WSCALE: u32 = 64; +pub const PF_OSFP_WSCALE_MOD: u32 = 128; +pub const PF_OSFP_WSCALE_DC: u32 = 256; +pub const PF_OSFP_MSS: u32 = 512; +pub const PF_OSFP_MSS_MOD: u32 = 1024; +pub const PF_OSFP_MSS_DC: u32 = 2048; +pub const PF_OSFP_DF: u32 = 4096; +pub const PF_OSFP_TS0: u32 = 8192; +pub const PF_OSFP_INET6: u32 = 16384; +pub const PF_OSFP_MAXTTL_OFFSET: u32 = 40; +pub const PF_OSFP_TCPOPT_NOP: u32 = 0; +pub const PF_OSFP_TCPOPT_WSCALE: u32 = 1; +pub const PF_OSFP_TCPOPT_MSS: u32 = 2; +pub const PF_OSFP_TCPOPT_SACK: u32 = 3; +pub const PF_OSFP_TCPOPT_TS: u32 = 4; +pub const PF_OSFP_TCPOPT_BITS: u32 = 3; +pub const PF_ANCHOR_NAME_SIZE: u32 = 64; +pub const PF_SKIP_IFP: u32 = 0; +pub const PF_SKIP_DIR: u32 = 1; +pub const PF_SKIP_AF: u32 = 2; +pub const PF_SKIP_PROTO: u32 = 3; +pub const PF_SKIP_SRC_ADDR: u32 = 4; +pub const PF_SKIP_SRC_PORT: u32 = 5; +pub const PF_SKIP_DST_ADDR: u32 = 6; +pub const PF_SKIP_DST_PORT: u32 = 7; +pub const PF_SKIP_COUNT: u32 = 8; +pub const PF_RULE_LABEL_SIZE: u32 = 64; +pub const PF_QNAME_SIZE: u32 = 64; +pub const PF_TAG_NAME_SIZE: u32 = 64; +pub const PF_OWNER_NAME_SIZE: u32 = 64; +pub const PF_STATE_NORMAL: u32 = 1; +pub const PF_STATE_MODULATE: u32 = 2; +pub const PF_STATE_SYNPROXY: u32 = 3; +pub const SCIDX_MASK: u32 = 15; +pub const SC_BE: u32 = 16; +pub const SC_BK_SYS: u32 = 17; +pub const SC_BK: u32 = 18; +pub const SC_RD: u32 = 19; +pub const SC_OAM: u32 = 20; +pub const SC_AV: u32 = 21; +pub const SC_RV: u32 = 22; +pub const SC_VI: u32 = 23; +pub const SC_SIG: u32 = 23; +pub const SC_VO: u32 = 24; +pub const SC_CTL: u32 = 25; +pub const DSCP_MASK: u32 = 252; +pub const DSCP_CUMASK: u32 = 3; +pub const DSCP_EF: u32 = 184; +pub const DSCP_AF11: u32 = 40; +pub const DSCP_AF12: u32 = 48; +pub const DSCP_AF13: u32 = 56; +pub const DSCP_AF21: u32 = 72; +pub const DSCP_AF22: u32 = 80; +pub const DSCP_AF23: u32 = 88; +pub const DSCP_AF31: u32 = 104; +pub const DSCP_AF32: u32 = 112; +pub const DSCP_AF33: u32 = 120; +pub const DSCP_AF41: u32 = 136; +pub const DSCP_AF42: u32 = 144; +pub const DSCP_AF43: u32 = 152; +pub const AF_CLASSMASK: u32 = 224; +pub const AF_DROPPRECMASK: u32 = 24; +pub const PF_FLUSH: u32 = 1; +pub const PF_FLUSH_GLOBAL: u32 = 2; +pub const PFDEV_PF: u32 = 0; +pub const PFDEV_PFM: u32 = 1; +pub const PFDEV_MAX: u32 = 2; +pub const PFRULE_DROP: u32 = 0; +pub const PFRULE_RETURNRST: u32 = 1; +pub const PFRULE_FRAGMENT: u32 = 2; +pub const PFRULE_RETURNICMP: u32 = 4; +pub const PFRULE_RETURN: u32 = 8; +pub const PFRULE_NOSYNC: u32 = 16; +pub const PFRULE_SRCTRACK: u32 = 32; +pub const PFRULE_RULESRCTRACK: u32 = 64; +pub const PFRULE_NODF: u32 = 256; +pub const PFRULE_FRAGCROP: u32 = 512; +pub const PFRULE_FRAGDROP: u32 = 1024; +pub const PFRULE_RANDOMID: u32 = 2048; +pub const PFRULE_REASSEMBLE_TCP: u32 = 4096; +pub const PFRULE_TOS: u32 = 8192; +pub const PFRULE_DSCP: u32 = 16384; +pub const PFRULE_SC: u32 = 32768; +pub const PFRULE_IFBOUND: u32 = 65536; +pub const PFRULE_PFM: u32 = 131072; +pub const PFSTATE_HIWAT: u32 = 10000; +pub const PFSTATE_ADAPT_START: u32 = 6000; +pub const PFSTATE_ADAPT_END: u32 = 12000; +pub const PFAPPSTATE_HIWAT: u32 = 10000; +pub const PF_TAG_NAME_SYSTEM_SERVICE: &[u8; 32] = b"com.apple.pf.system_service_tag\0"; +pub const PF_TAG_NAME_STACK_DROP: &[u8; 28] = b"com.apple.pf.stack_drop_tag\0"; +pub const PF_THRESHOLD_MULT: u32 = 1000; +pub const PF_THRESHOLD_MAX: u32 = 4294967; +pub const PFSNODE_HIWAT: u32 = 10000; +pub const PFSTATE_NOSYNC: u32 = 1; +pub const PFSTATE_FROMSYNC: u32 = 2; +pub const PFSTATE_STALE: u32 = 4; +pub const PFSYNC_SCRUB_FLAG_VALID: u32 = 1; +pub const PFSYNC_FLAG_COMPRESS: u32 = 1; +pub const PFSYNC_FLAG_STALE: u32 = 2; +pub const PFSYNC_FLAG_SRCNODE: u32 = 4; +pub const PFSYNC_FLAG_NATSRCNODE: u32 = 8; +pub const PF_RESERVED_ANCHOR: &[u8; 4] = b"_pf\0"; +pub const PFR_TFLAG_PERSIST: u32 = 1; +pub const PFR_TFLAG_CONST: u32 = 2; +pub const PFR_TFLAG_ACTIVE: u32 = 4; +pub const PFR_TFLAG_INACTIVE: u32 = 8; +pub const PFR_TFLAG_REFERENCED: u32 = 16; +pub const PFR_TFLAG_REFDANCHOR: u32 = 32; +pub const PFR_TFLAG_USRMASK: u32 = 3; +pub const PFR_TFLAG_SETMASK: u32 = 60; +pub const PFR_TFLAG_ALLMASK: u32 = 63; +pub const PFI_IFLAG_SKIP: u32 = 256; +pub const PF_DPORT_RANGE: u32 = 1; +pub const PF_RPORT_RANGE: u32 = 2; +pub const PFRES_MATCH: u32 = 0; +pub const PFRES_BADOFF: u32 = 1; +pub const PFRES_FRAG: u32 = 2; +pub const PFRES_SHORT: u32 = 3; +pub const PFRES_NORM: u32 = 4; +pub const PFRES_MEMORY: u32 = 5; +pub const PFRES_TS: u32 = 6; +pub const PFRES_CONGEST: u32 = 7; +pub const PFRES_IPOPTIONS: u32 = 8; +pub const PFRES_PROTCKSUM: u32 = 9; +pub const PFRES_BADSTATE: u32 = 10; +pub const PFRES_STATEINS: u32 = 11; +pub const PFRES_MAXSTATES: u32 = 12; +pub const PFRES_SRCLIMIT: u32 = 13; +pub const PFRES_SYNPROXY: u32 = 14; +pub const PFRES_DUMMYNET: u32 = 15; +pub const PFRES_MAX: u32 = 16; +pub const LCNT_STATES: u32 = 0; +pub const LCNT_SRCSTATES: u32 = 1; +pub const LCNT_SRCNODES: u32 = 2; +pub const LCNT_SRCCONN: u32 = 3; +pub const LCNT_SRCCONNRATE: u32 = 4; +pub const LCNT_OVERLOAD_TABLE: u32 = 5; +pub const LCNT_OVERLOAD_FLUSH: u32 = 6; +pub const LCNT_MAX: u32 = 7; +pub const PFUDPS_NO_TRAFFIC: u32 = 0; +pub const PFUDPS_SINGLE: u32 = 1; +pub const PFUDPS_MULTIPLE: u32 = 2; +pub const PFUDPS_NSTATES: u32 = 3; +pub const PFGRE1S_NO_TRAFFIC: u32 = 0; +pub const PFGRE1S_INITIATING: u32 = 1; +pub const PFGRE1S_ESTABLISHED: u32 = 2; +pub const PFGRE1S_NSTATES: u32 = 3; +pub const PFESPS_NO_TRAFFIC: u32 = 0; +pub const PFESPS_INITIATING: u32 = 1; +pub const PFESPS_ESTABLISHED: u32 = 2; +pub const PFESPS_NSTATES: u32 = 3; +pub const PFOTHERS_NO_TRAFFIC: u32 = 0; +pub const PFOTHERS_SINGLE: u32 = 1; +pub const PFOTHERS_MULTIPLE: u32 = 2; +pub const PFOTHERS_NSTATES: u32 = 3; +pub const FCNT_STATE_SEARCH: u32 = 0; +pub const FCNT_STATE_INSERT: u32 = 1; +pub const FCNT_STATE_REMOVALS: u32 = 2; +pub const FCNT_MAX: u32 = 3; +pub const SCNT_SRC_NODE_SEARCH: u32 = 0; +pub const SCNT_SRC_NODE_INSERT: u32 = 1; +pub const SCNT_SRC_NODE_REMOVALS: u32 = 2; +pub const SCNT_MAX: u32 = 3; +pub const PF_ALTQ_BW_ABSOLUTE: u32 = 1; +pub const PF_ALTQ_BW_PERCENT: u32 = 2; +pub const PF_ALTQF_TBR: u32 = 1; +pub const PF_ALTQ_QRF_WEIGHT: u32 = 1; +pub const PFFRAG_FRENT_HIWAT: u32 = 5000; +pub const PFFRAG_FRAG_HIWAT: u32 = 1000; +pub const PFFRAG_FRCENT_HIWAT: u32 = 50000; +pub const PFFRAG_FRCACHE_HIWAT: u32 = 10000; +pub const PFR_KTABLE_HIWAT: u32 = 1000; +pub const PFR_KENTRY_HIWAT: u32 = 200000; +pub const PFR_KENTRY_HIWAT_SMALL: u32 = 100000; +pub const PFTOK_PROCNAME_LEN: u32 = 64; +pub const PFR_FLAG_ATOMIC: u32 = 1; +pub const PFR_FLAG_DUMMY: u32 = 2; +pub const PFR_FLAG_FEEDBACK: u32 = 4; +pub const PFR_FLAG_CLSTATS: u32 = 8; +pub const PFR_FLAG_ADDRSTOO: u32 = 16; +pub const PFR_FLAG_REPLACE: u32 = 32; +pub const PFR_FLAG_ALLRSETS: u32 = 64; +pub const PFR_FLAG_ALLMASK: u32 = 127; +pub type __int8_t = ::std::os::raw::c_schar; +pub type __uint8_t = ::std::os::raw::c_uchar; +pub type __int16_t = ::std::os::raw::c_short; +pub type __uint16_t = ::std::os::raw::c_ushort; +pub type __int32_t = ::std::os::raw::c_int; +pub type __uint32_t = ::std::os::raw::c_uint; +pub type __int64_t = ::std::os::raw::c_longlong; +pub type __uint64_t = ::std::os::raw::c_ulonglong; +pub type __darwin_intptr_t = ::std::os::raw::c_long; +pub type __darwin_natural_t = ::std::os::raw::c_uint; +pub type __darwin_ct_rune_t = ::std::os::raw::c_int; +#[repr(C)] +#[derive(Copy, Clone)] +pub union __mbstate_t { + pub __mbstate8: [::std::os::raw::c_char; 128usize], + pub _mbstateL: ::std::os::raw::c_longlong, +} +#[test] +fn bindgen_test_layout___mbstate_t() { + const UNINIT: ::std::mem::MaybeUninit<__mbstate_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__mbstate_t>(), + 128usize, + concat!("Size of: ", stringify!(__mbstate_t)) + ); + assert_eq!( + ::std::mem::align_of::<__mbstate_t>(), + 8usize, + concat!("Alignment of ", stringify!(__mbstate_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__mbstate8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__mbstate_t), + "::", + stringify!(__mbstate8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._mbstateL) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__mbstate_t), + "::", + stringify!(_mbstateL) + ) + ); +} +pub type __darwin_mbstate_t = __mbstate_t; +pub type __darwin_ptrdiff_t = ::std::os::raw::c_long; +pub type __darwin_size_t = ::std::os::raw::c_ulong; +pub type __darwin_va_list = __builtin_va_list; +pub type __darwin_wchar_t = ::std::os::raw::c_int; +pub type __darwin_rune_t = __darwin_wchar_t; +pub type __darwin_wint_t = ::std::os::raw::c_int; +pub type __darwin_clock_t = ::std::os::raw::c_ulong; +pub type __darwin_socklen_t = __uint32_t; +pub type __darwin_ssize_t = ::std::os::raw::c_long; +pub type __darwin_time_t = ::std::os::raw::c_long; +pub type __darwin_blkcnt_t = __int64_t; +pub type __darwin_blksize_t = __int32_t; +pub type __darwin_dev_t = __int32_t; +pub type __darwin_fsblkcnt_t = ::std::os::raw::c_uint; +pub type __darwin_fsfilcnt_t = ::std::os::raw::c_uint; +pub type __darwin_gid_t = __uint32_t; +pub type __darwin_id_t = __uint32_t; +pub type __darwin_ino64_t = __uint64_t; +pub type __darwin_ino_t = __darwin_ino64_t; +pub type __darwin_mach_port_name_t = __darwin_natural_t; +pub type __darwin_mach_port_t = __darwin_mach_port_name_t; +pub type __darwin_mode_t = __uint16_t; +pub type __darwin_off_t = __int64_t; +pub type __darwin_pid_t = __int32_t; +pub type __darwin_sigset_t = __uint32_t; +pub type __darwin_suseconds_t = __int32_t; +pub type __darwin_uid_t = __uint32_t; +pub type __darwin_useconds_t = __uint32_t; +pub type __darwin_uuid_t = [::std::os::raw::c_uchar; 16usize]; +pub type __darwin_uuid_string_t = [::std::os::raw::c_char; 37usize]; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_pthread_handler_rec { + pub __routine: ::std::option::Option, + pub __arg: *mut ::std::os::raw::c_void, + pub __next: *mut __darwin_pthread_handler_rec, +} +#[test] +fn bindgen_test_layout___darwin_pthread_handler_rec() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_pthread_handler_rec> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_pthread_handler_rec>(), + 24usize, + concat!("Size of: ", stringify!(__darwin_pthread_handler_rec)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_pthread_handler_rec>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_pthread_handler_rec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__routine) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_pthread_handler_rec), + "::", + stringify!(__routine) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__arg) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_pthread_handler_rec), + "::", + stringify!(__arg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__next) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_pthread_handler_rec), + "::", + stringify!(__next) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _opaque_pthread_attr_t { + pub __sig: ::std::os::raw::c_long, + pub __opaque: [::std::os::raw::c_char; 56usize], +} +#[test] +fn bindgen_test_layout__opaque_pthread_attr_t() { + const UNINIT: ::std::mem::MaybeUninit<_opaque_pthread_attr_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_opaque_pthread_attr_t>(), + 64usize, + concat!("Size of: ", stringify!(_opaque_pthread_attr_t)) + ); + assert_eq!( + ::std::mem::align_of::<_opaque_pthread_attr_t>(), + 8usize, + concat!("Alignment of ", stringify!(_opaque_pthread_attr_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sig) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_attr_t), + "::", + stringify!(__sig) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opaque) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_attr_t), + "::", + stringify!(__opaque) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _opaque_pthread_cond_t { + pub __sig: ::std::os::raw::c_long, + pub __opaque: [::std::os::raw::c_char; 40usize], +} +#[test] +fn bindgen_test_layout__opaque_pthread_cond_t() { + const UNINIT: ::std::mem::MaybeUninit<_opaque_pthread_cond_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_opaque_pthread_cond_t>(), + 48usize, + concat!("Size of: ", stringify!(_opaque_pthread_cond_t)) + ); + assert_eq!( + ::std::mem::align_of::<_opaque_pthread_cond_t>(), + 8usize, + concat!("Alignment of ", stringify!(_opaque_pthread_cond_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sig) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_cond_t), + "::", + stringify!(__sig) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opaque) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_cond_t), + "::", + stringify!(__opaque) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _opaque_pthread_condattr_t { + pub __sig: ::std::os::raw::c_long, + pub __opaque: [::std::os::raw::c_char; 8usize], +} +#[test] +fn bindgen_test_layout__opaque_pthread_condattr_t() { + const UNINIT: ::std::mem::MaybeUninit<_opaque_pthread_condattr_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_opaque_pthread_condattr_t>(), + 16usize, + concat!("Size of: ", stringify!(_opaque_pthread_condattr_t)) + ); + assert_eq!( + ::std::mem::align_of::<_opaque_pthread_condattr_t>(), + 8usize, + concat!("Alignment of ", stringify!(_opaque_pthread_condattr_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sig) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_condattr_t), + "::", + stringify!(__sig) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opaque) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_condattr_t), + "::", + stringify!(__opaque) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _opaque_pthread_mutex_t { + pub __sig: ::std::os::raw::c_long, + pub __opaque: [::std::os::raw::c_char; 56usize], +} +#[test] +fn bindgen_test_layout__opaque_pthread_mutex_t() { + const UNINIT: ::std::mem::MaybeUninit<_opaque_pthread_mutex_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_opaque_pthread_mutex_t>(), + 64usize, + concat!("Size of: ", stringify!(_opaque_pthread_mutex_t)) + ); + assert_eq!( + ::std::mem::align_of::<_opaque_pthread_mutex_t>(), + 8usize, + concat!("Alignment of ", stringify!(_opaque_pthread_mutex_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sig) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_mutex_t), + "::", + stringify!(__sig) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opaque) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_mutex_t), + "::", + stringify!(__opaque) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _opaque_pthread_mutexattr_t { + pub __sig: ::std::os::raw::c_long, + pub __opaque: [::std::os::raw::c_char; 8usize], +} +#[test] +fn bindgen_test_layout__opaque_pthread_mutexattr_t() { + const UNINIT: ::std::mem::MaybeUninit<_opaque_pthread_mutexattr_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_opaque_pthread_mutexattr_t>(), + 16usize, + concat!("Size of: ", stringify!(_opaque_pthread_mutexattr_t)) + ); + assert_eq!( + ::std::mem::align_of::<_opaque_pthread_mutexattr_t>(), + 8usize, + concat!("Alignment of ", stringify!(_opaque_pthread_mutexattr_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sig) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_mutexattr_t), + "::", + stringify!(__sig) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opaque) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_mutexattr_t), + "::", + stringify!(__opaque) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _opaque_pthread_once_t { + pub __sig: ::std::os::raw::c_long, + pub __opaque: [::std::os::raw::c_char; 8usize], +} +#[test] +fn bindgen_test_layout__opaque_pthread_once_t() { + const UNINIT: ::std::mem::MaybeUninit<_opaque_pthread_once_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_opaque_pthread_once_t>(), + 16usize, + concat!("Size of: ", stringify!(_opaque_pthread_once_t)) + ); + assert_eq!( + ::std::mem::align_of::<_opaque_pthread_once_t>(), + 8usize, + concat!("Alignment of ", stringify!(_opaque_pthread_once_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sig) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_once_t), + "::", + stringify!(__sig) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opaque) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_once_t), + "::", + stringify!(__opaque) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _opaque_pthread_rwlock_t { + pub __sig: ::std::os::raw::c_long, + pub __opaque: [::std::os::raw::c_char; 192usize], +} +#[test] +fn bindgen_test_layout__opaque_pthread_rwlock_t() { + const UNINIT: ::std::mem::MaybeUninit<_opaque_pthread_rwlock_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_opaque_pthread_rwlock_t>(), + 200usize, + concat!("Size of: ", stringify!(_opaque_pthread_rwlock_t)) + ); + assert_eq!( + ::std::mem::align_of::<_opaque_pthread_rwlock_t>(), + 8usize, + concat!("Alignment of ", stringify!(_opaque_pthread_rwlock_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sig) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_rwlock_t), + "::", + stringify!(__sig) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opaque) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_rwlock_t), + "::", + stringify!(__opaque) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _opaque_pthread_rwlockattr_t { + pub __sig: ::std::os::raw::c_long, + pub __opaque: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout__opaque_pthread_rwlockattr_t() { + const UNINIT: ::std::mem::MaybeUninit<_opaque_pthread_rwlockattr_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_opaque_pthread_rwlockattr_t>(), + 24usize, + concat!("Size of: ", stringify!(_opaque_pthread_rwlockattr_t)) + ); + assert_eq!( + ::std::mem::align_of::<_opaque_pthread_rwlockattr_t>(), + 8usize, + concat!("Alignment of ", stringify!(_opaque_pthread_rwlockattr_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sig) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_rwlockattr_t), + "::", + stringify!(__sig) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opaque) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_rwlockattr_t), + "::", + stringify!(__opaque) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _opaque_pthread_t { + pub __sig: ::std::os::raw::c_long, + pub __cleanup_stack: *mut __darwin_pthread_handler_rec, + pub __opaque: [::std::os::raw::c_char; 8176usize], +} +#[test] +fn bindgen_test_layout__opaque_pthread_t() { + const UNINIT: ::std::mem::MaybeUninit<_opaque_pthread_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_opaque_pthread_t>(), + 8192usize, + concat!("Size of: ", stringify!(_opaque_pthread_t)) + ); + assert_eq!( + ::std::mem::align_of::<_opaque_pthread_t>(), + 8usize, + concat!("Alignment of ", stringify!(_opaque_pthread_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sig) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_t), + "::", + stringify!(__sig) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__cleanup_stack) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_t), + "::", + stringify!(__cleanup_stack) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opaque) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(_opaque_pthread_t), + "::", + stringify!(__opaque) + ) + ); +} +pub type __darwin_pthread_attr_t = _opaque_pthread_attr_t; +pub type __darwin_pthread_cond_t = _opaque_pthread_cond_t; +pub type __darwin_pthread_condattr_t = _opaque_pthread_condattr_t; +pub type __darwin_pthread_key_t = ::std::os::raw::c_ulong; +pub type __darwin_pthread_mutex_t = _opaque_pthread_mutex_t; +pub type __darwin_pthread_mutexattr_t = _opaque_pthread_mutexattr_t; +pub type __darwin_pthread_once_t = _opaque_pthread_once_t; +pub type __darwin_pthread_rwlock_t = _opaque_pthread_rwlock_t; +pub type __darwin_pthread_rwlockattr_t = _opaque_pthread_rwlockattr_t; +pub type __darwin_pthread_t = *mut _opaque_pthread_t; +pub type u_int8_t = ::std::os::raw::c_uchar; +pub type u_int16_t = ::std::os::raw::c_ushort; +pub type u_int32_t = ::std::os::raw::c_uint; +pub type u_int64_t = ::std::os::raw::c_ulonglong; +pub type register_t = i64; +pub type user_addr_t = u_int64_t; +pub type user_size_t = u_int64_t; +pub type user_ssize_t = i64; +pub type user_long_t = i64; +pub type user_ulong_t = u_int64_t; +pub type user_time_t = i64; +pub type user_off_t = i64; +pub type syscall_arg_t = u_int64_t; +pub type u_char = ::std::os::raw::c_uchar; +pub type u_short = ::std::os::raw::c_ushort; +pub type u_int = ::std::os::raw::c_uint; +pub type u_long = ::std::os::raw::c_ulong; +pub type ushort = ::std::os::raw::c_ushort; +pub type uint = ::std::os::raw::c_uint; +pub type u_quad_t = u_int64_t; +pub type quad_t = i64; +pub type qaddr_t = *mut quad_t; +pub type caddr_t = *mut ::std::os::raw::c_char; +pub type daddr_t = i32; +pub type dev_t = __darwin_dev_t; +pub type fixpt_t = u_int32_t; +pub type blkcnt_t = __darwin_blkcnt_t; +pub type blksize_t = __darwin_blksize_t; +pub type gid_t = __darwin_gid_t; +pub type in_addr_t = __uint32_t; +pub type in_port_t = __uint16_t; +pub type ino_t = __darwin_ino_t; +pub type ino64_t = __darwin_ino64_t; +pub type key_t = __int32_t; +pub type mode_t = __darwin_mode_t; +pub type nlink_t = __uint16_t; +pub type id_t = __darwin_id_t; +pub type pid_t = __darwin_pid_t; +pub type off_t = __darwin_off_t; +pub type segsz_t = i32; +pub type swblk_t = i32; +pub type uid_t = __darwin_uid_t; +pub type clock_t = __darwin_clock_t; +pub type time_t = __darwin_time_t; +pub type useconds_t = __darwin_useconds_t; +pub type suseconds_t = __darwin_suseconds_t; +pub type rsize_t = __darwin_size_t; +pub type errno_t = ::std::os::raw::c_int; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct fd_set { + pub fds_bits: [__int32_t; 32usize], +} +#[test] +fn bindgen_test_layout_fd_set() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(fd_set)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(fd_set)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fds_bits) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(fd_set), "::", stringify!(fds_bits)) + ); +} +extern "C" { + pub fn __darwin_check_fd_set_overflow( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_void, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +pub type fd_mask = __int32_t; +pub type pthread_attr_t = __darwin_pthread_attr_t; +pub type pthread_cond_t = __darwin_pthread_cond_t; +pub type pthread_condattr_t = __darwin_pthread_condattr_t; +pub type pthread_mutex_t = __darwin_pthread_mutex_t; +pub type pthread_mutexattr_t = __darwin_pthread_mutexattr_t; +pub type pthread_once_t = __darwin_pthread_once_t; +pub type pthread_rwlock_t = __darwin_pthread_rwlock_t; +pub type pthread_rwlockattr_t = __darwin_pthread_rwlockattr_t; +pub type pthread_t = __darwin_pthread_t; +pub type pthread_key_t = __darwin_pthread_key_t; +pub type fsblkcnt_t = __darwin_fsblkcnt_t; +pub type fsfilcnt_t = __darwin_fsfilcnt_t; +pub type sig_atomic_t = ::std::os::raw::c_int; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_i386_thread_state { + pub __eax: ::std::os::raw::c_uint, + pub __ebx: ::std::os::raw::c_uint, + pub __ecx: ::std::os::raw::c_uint, + pub __edx: ::std::os::raw::c_uint, + pub __edi: ::std::os::raw::c_uint, + pub __esi: ::std::os::raw::c_uint, + pub __ebp: ::std::os::raw::c_uint, + pub __esp: ::std::os::raw::c_uint, + pub __ss: ::std::os::raw::c_uint, + pub __eflags: ::std::os::raw::c_uint, + pub __eip: ::std::os::raw::c_uint, + pub __cs: ::std::os::raw::c_uint, + pub __ds: ::std::os::raw::c_uint, + pub __es: ::std::os::raw::c_uint, + pub __fs: ::std::os::raw::c_uint, + pub __gs: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout___darwin_i386_thread_state() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_i386_thread_state> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_i386_thread_state>(), + 64usize, + concat!("Size of: ", stringify!(__darwin_i386_thread_state)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_i386_thread_state>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_i386_thread_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__eax) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__eax) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ebx) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__ebx) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ecx) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__ecx) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__edx) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__edx) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__edi) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__edi) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__esi) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__esi) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ebp) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__ebp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__esp) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__esp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__eflags) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__eflags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__eip) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__eip) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__cs) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__cs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ds) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__ds) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 52usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__fs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__gs) as usize - ptr as usize }, + 60usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_thread_state), + "::", + stringify!(__gs) + ) + ); +} +#[repr(C)] +#[repr(align(2))] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_fp_control { + pub _bitfield_align_1: [u8; 0], + pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>, +} +#[test] +fn bindgen_test_layout___darwin_fp_control() { + assert_eq!( + ::std::mem::size_of::<__darwin_fp_control>(), + 2usize, + concat!("Size of: ", stringify!(__darwin_fp_control)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_fp_control>(), + 2usize, + concat!("Alignment of ", stringify!(__darwin_fp_control)) + ); +} +impl __darwin_fp_control { + #[inline] + pub fn __invalid(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u16) } + } + + #[inline] + pub fn set___invalid(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(0usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __denorm(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u16) } + } + + #[inline] + pub fn set___denorm(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(1usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __zdiv(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u16) } + } + + #[inline] + pub fn set___zdiv(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(2usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __ovrfl(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u16) } + } + + #[inline] + pub fn set___ovrfl(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(3usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __undfl(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u16) } + } + + #[inline] + pub fn set___undfl(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(4usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __precis(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u16) } + } + + #[inline] + pub fn set___precis(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(5usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __pc(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 2u8) as u16) } + } + + #[inline] + pub fn set___pc(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(8usize, 2u8, val as u64) + } + } + + #[inline] + pub fn __rc(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 2u8) as u16) } + } + + #[inline] + pub fn set___rc(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(10usize, 2u8, val as u64) + } + } + + #[inline] + pub fn new_bitfield_1( + __invalid: ::std::os::raw::c_ushort, + __denorm: ::std::os::raw::c_ushort, + __zdiv: ::std::os::raw::c_ushort, + __ovrfl: ::std::os::raw::c_ushort, + __undfl: ::std::os::raw::c_ushort, + __precis: ::std::os::raw::c_ushort, + __pc: ::std::os::raw::c_ushort, + __rc: ::std::os::raw::c_ushort, + ) -> __BindgenBitfieldUnit<[u8; 2usize]> { + let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 2usize]> = Default::default(); + __bindgen_bitfield_unit.set(0usize, 1u8, { + let __invalid: u16 = unsafe { ::std::mem::transmute(__invalid) }; + __invalid as u64 + }); + __bindgen_bitfield_unit.set(1usize, 1u8, { + let __denorm: u16 = unsafe { ::std::mem::transmute(__denorm) }; + __denorm as u64 + }); + __bindgen_bitfield_unit.set(2usize, 1u8, { + let __zdiv: u16 = unsafe { ::std::mem::transmute(__zdiv) }; + __zdiv as u64 + }); + __bindgen_bitfield_unit.set(3usize, 1u8, { + let __ovrfl: u16 = unsafe { ::std::mem::transmute(__ovrfl) }; + __ovrfl as u64 + }); + __bindgen_bitfield_unit.set(4usize, 1u8, { + let __undfl: u16 = unsafe { ::std::mem::transmute(__undfl) }; + __undfl as u64 + }); + __bindgen_bitfield_unit.set(5usize, 1u8, { + let __precis: u16 = unsafe { ::std::mem::transmute(__precis) }; + __precis as u64 + }); + __bindgen_bitfield_unit.set(8usize, 2u8, { + let __pc: u16 = unsafe { ::std::mem::transmute(__pc) }; + __pc as u64 + }); + __bindgen_bitfield_unit.set(10usize, 2u8, { + let __rc: u16 = unsafe { ::std::mem::transmute(__rc) }; + __rc as u64 + }); + __bindgen_bitfield_unit + } +} +pub type __darwin_fp_control_t = __darwin_fp_control; +#[repr(C)] +#[repr(align(2))] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_fp_status { + pub _bitfield_align_1: [u8; 0], + pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>, +} +#[test] +fn bindgen_test_layout___darwin_fp_status() { + assert_eq!( + ::std::mem::size_of::<__darwin_fp_status>(), + 2usize, + concat!("Size of: ", stringify!(__darwin_fp_status)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_fp_status>(), + 2usize, + concat!("Alignment of ", stringify!(__darwin_fp_status)) + ); +} +impl __darwin_fp_status { + #[inline] + pub fn __invalid(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u16) } + } + + #[inline] + pub fn set___invalid(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(0usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __denorm(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u16) } + } + + #[inline] + pub fn set___denorm(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(1usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __zdiv(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u16) } + } + + #[inline] + pub fn set___zdiv(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(2usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __ovrfl(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u16) } + } + + #[inline] + pub fn set___ovrfl(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(3usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __undfl(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u16) } + } + + #[inline] + pub fn set___undfl(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(4usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __precis(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u16) } + } + + #[inline] + pub fn set___precis(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(5usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __stkflt(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 1u8) as u16) } + } + + #[inline] + pub fn set___stkflt(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(6usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __errsumm(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u16) } + } + + #[inline] + pub fn set___errsumm(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(7usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __c0(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 1u8) as u16) } + } + + #[inline] + pub fn set___c0(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(8usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __c1(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(9usize, 1u8) as u16) } + } + + #[inline] + pub fn set___c1(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(9usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __c2(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 1u8) as u16) } + } + + #[inline] + pub fn set___c2(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(10usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __tos(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(11usize, 3u8) as u16) } + } + + #[inline] + pub fn set___tos(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(11usize, 3u8, val as u64) + } + } + + #[inline] + pub fn __c3(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(14usize, 1u8) as u16) } + } + + #[inline] + pub fn set___c3(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(14usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __busy(&self) -> ::std::os::raw::c_ushort { + unsafe { ::std::mem::transmute(self._bitfield_1.get(15usize, 1u8) as u16) } + } + + #[inline] + pub fn set___busy(&mut self, val: ::std::os::raw::c_ushort) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(15usize, 1u8, val as u64) + } + } + + #[inline] + pub fn new_bitfield_1( + __invalid: ::std::os::raw::c_ushort, + __denorm: ::std::os::raw::c_ushort, + __zdiv: ::std::os::raw::c_ushort, + __ovrfl: ::std::os::raw::c_ushort, + __undfl: ::std::os::raw::c_ushort, + __precis: ::std::os::raw::c_ushort, + __stkflt: ::std::os::raw::c_ushort, + __errsumm: ::std::os::raw::c_ushort, + __c0: ::std::os::raw::c_ushort, + __c1: ::std::os::raw::c_ushort, + __c2: ::std::os::raw::c_ushort, + __tos: ::std::os::raw::c_ushort, + __c3: ::std::os::raw::c_ushort, + __busy: ::std::os::raw::c_ushort, + ) -> __BindgenBitfieldUnit<[u8; 2usize]> { + let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 2usize]> = Default::default(); + __bindgen_bitfield_unit.set(0usize, 1u8, { + let __invalid: u16 = unsafe { ::std::mem::transmute(__invalid) }; + __invalid as u64 + }); + __bindgen_bitfield_unit.set(1usize, 1u8, { + let __denorm: u16 = unsafe { ::std::mem::transmute(__denorm) }; + __denorm as u64 + }); + __bindgen_bitfield_unit.set(2usize, 1u8, { + let __zdiv: u16 = unsafe { ::std::mem::transmute(__zdiv) }; + __zdiv as u64 + }); + __bindgen_bitfield_unit.set(3usize, 1u8, { + let __ovrfl: u16 = unsafe { ::std::mem::transmute(__ovrfl) }; + __ovrfl as u64 + }); + __bindgen_bitfield_unit.set(4usize, 1u8, { + let __undfl: u16 = unsafe { ::std::mem::transmute(__undfl) }; + __undfl as u64 + }); + __bindgen_bitfield_unit.set(5usize, 1u8, { + let __precis: u16 = unsafe { ::std::mem::transmute(__precis) }; + __precis as u64 + }); + __bindgen_bitfield_unit.set(6usize, 1u8, { + let __stkflt: u16 = unsafe { ::std::mem::transmute(__stkflt) }; + __stkflt as u64 + }); + __bindgen_bitfield_unit.set(7usize, 1u8, { + let __errsumm: u16 = unsafe { ::std::mem::transmute(__errsumm) }; + __errsumm as u64 + }); + __bindgen_bitfield_unit.set(8usize, 1u8, { + let __c0: u16 = unsafe { ::std::mem::transmute(__c0) }; + __c0 as u64 + }); + __bindgen_bitfield_unit.set(9usize, 1u8, { + let __c1: u16 = unsafe { ::std::mem::transmute(__c1) }; + __c1 as u64 + }); + __bindgen_bitfield_unit.set(10usize, 1u8, { + let __c2: u16 = unsafe { ::std::mem::transmute(__c2) }; + __c2 as u64 + }); + __bindgen_bitfield_unit.set(11usize, 3u8, { + let __tos: u16 = unsafe { ::std::mem::transmute(__tos) }; + __tos as u64 + }); + __bindgen_bitfield_unit.set(14usize, 1u8, { + let __c3: u16 = unsafe { ::std::mem::transmute(__c3) }; + __c3 as u64 + }); + __bindgen_bitfield_unit.set(15usize, 1u8, { + let __busy: u16 = unsafe { ::std::mem::transmute(__busy) }; + __busy as u64 + }); + __bindgen_bitfield_unit + } +} +pub type __darwin_fp_status_t = __darwin_fp_status; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mmst_reg { + pub __mmst_reg: [::std::os::raw::c_char; 10usize], + pub __mmst_rsrv: [::std::os::raw::c_char; 6usize], +} +#[test] +fn bindgen_test_layout___darwin_mmst_reg() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mmst_reg> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mmst_reg>(), + 16usize, + concat!("Size of: ", stringify!(__darwin_mmst_reg)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mmst_reg>(), + 1usize, + concat!("Alignment of ", stringify!(__darwin_mmst_reg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__mmst_reg) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mmst_reg), + "::", + stringify!(__mmst_reg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__mmst_rsrv) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mmst_reg), + "::", + stringify!(__mmst_rsrv) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_xmm_reg { + pub __xmm_reg: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout___darwin_xmm_reg() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_xmm_reg> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_xmm_reg>(), + 16usize, + concat!("Size of: ", stringify!(__darwin_xmm_reg)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_xmm_reg>(), + 1usize, + concat!("Alignment of ", stringify!(__darwin_xmm_reg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__xmm_reg) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_xmm_reg), + "::", + stringify!(__xmm_reg) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_ymm_reg { + pub __ymm_reg: [::std::os::raw::c_char; 32usize], +} +#[test] +fn bindgen_test_layout___darwin_ymm_reg() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_ymm_reg> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_ymm_reg>(), + 32usize, + concat!("Size of: ", stringify!(__darwin_ymm_reg)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_ymm_reg>(), + 1usize, + concat!("Alignment of ", stringify!(__darwin_ymm_reg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ymm_reg) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_ymm_reg), + "::", + stringify!(__ymm_reg) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_zmm_reg { + pub __zmm_reg: [::std::os::raw::c_char; 64usize], +} +#[test] +fn bindgen_test_layout___darwin_zmm_reg() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_zmm_reg> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_zmm_reg>(), + 64usize, + concat!("Size of: ", stringify!(__darwin_zmm_reg)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_zmm_reg>(), + 1usize, + concat!("Alignment of ", stringify!(__darwin_zmm_reg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__zmm_reg) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_zmm_reg), + "::", + stringify!(__zmm_reg) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_opmask_reg { + pub __opmask_reg: [::std::os::raw::c_char; 8usize], +} +#[test] +fn bindgen_test_layout___darwin_opmask_reg() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_opmask_reg> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_opmask_reg>(), + 8usize, + concat!("Size of: ", stringify!(__darwin_opmask_reg)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_opmask_reg>(), + 1usize, + concat!("Alignment of ", stringify!(__darwin_opmask_reg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__opmask_reg) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_opmask_reg), + "::", + stringify!(__opmask_reg) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_i386_float_state { + pub __fpu_reserved: [::std::os::raw::c_int; 2usize], + pub __fpu_fcw: __darwin_fp_control, + pub __fpu_fsw: __darwin_fp_status, + pub __fpu_ftw: __uint8_t, + pub __fpu_rsrv1: __uint8_t, + pub __fpu_fop: __uint16_t, + pub __fpu_ip: __uint32_t, + pub __fpu_cs: __uint16_t, + pub __fpu_rsrv2: __uint16_t, + pub __fpu_dp: __uint32_t, + pub __fpu_ds: __uint16_t, + pub __fpu_rsrv3: __uint16_t, + pub __fpu_mxcsr: __uint32_t, + pub __fpu_mxcsrmask: __uint32_t, + pub __fpu_stmm0: __darwin_mmst_reg, + pub __fpu_stmm1: __darwin_mmst_reg, + pub __fpu_stmm2: __darwin_mmst_reg, + pub __fpu_stmm3: __darwin_mmst_reg, + pub __fpu_stmm4: __darwin_mmst_reg, + pub __fpu_stmm5: __darwin_mmst_reg, + pub __fpu_stmm6: __darwin_mmst_reg, + pub __fpu_stmm7: __darwin_mmst_reg, + pub __fpu_xmm0: __darwin_xmm_reg, + pub __fpu_xmm1: __darwin_xmm_reg, + pub __fpu_xmm2: __darwin_xmm_reg, + pub __fpu_xmm3: __darwin_xmm_reg, + pub __fpu_xmm4: __darwin_xmm_reg, + pub __fpu_xmm5: __darwin_xmm_reg, + pub __fpu_xmm6: __darwin_xmm_reg, + pub __fpu_xmm7: __darwin_xmm_reg, + pub __fpu_rsrv4: [::std::os::raw::c_char; 224usize], + pub __fpu_reserved1: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___darwin_i386_float_state() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_i386_float_state> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_i386_float_state>(), + 524usize, + concat!("Size of: ", stringify!(__darwin_i386_float_state)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_i386_float_state>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_i386_float_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fcw) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_fcw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fsw) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_fsw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ftw) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_ftw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv1) as usize - ptr as usize }, + 13usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_rsrv1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fop) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_fop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ip) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_ip) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_cs) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_cs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv2) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_rsrv2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_dp) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_dp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ds) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_ds) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv3) as usize - ptr as usize }, + 30usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_rsrv3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_mxcsr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsrmask) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_mxcsrmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm0) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_stmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm1) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_stmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm2) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_stmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm3) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_stmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm4) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_stmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm5) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_stmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm6) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_stmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm7) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_stmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm0) as usize - ptr as usize }, + 168usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_xmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm1) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_xmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm2) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_xmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm3) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_xmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm4) as usize - ptr as usize }, + 232usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_xmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm5) as usize - ptr as usize }, + 248usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_xmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm6) as usize - ptr as usize }, + 264usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_xmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm7) as usize - ptr as usize }, + 280usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_xmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv4) as usize - ptr as usize }, + 296usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_rsrv4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved1) as usize - ptr as usize }, + 520usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_float_state), + "::", + stringify!(__fpu_reserved1) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_i386_avx_state { + pub __fpu_reserved: [::std::os::raw::c_int; 2usize], + pub __fpu_fcw: __darwin_fp_control, + pub __fpu_fsw: __darwin_fp_status, + pub __fpu_ftw: __uint8_t, + pub __fpu_rsrv1: __uint8_t, + pub __fpu_fop: __uint16_t, + pub __fpu_ip: __uint32_t, + pub __fpu_cs: __uint16_t, + pub __fpu_rsrv2: __uint16_t, + pub __fpu_dp: __uint32_t, + pub __fpu_ds: __uint16_t, + pub __fpu_rsrv3: __uint16_t, + pub __fpu_mxcsr: __uint32_t, + pub __fpu_mxcsrmask: __uint32_t, + pub __fpu_stmm0: __darwin_mmst_reg, + pub __fpu_stmm1: __darwin_mmst_reg, + pub __fpu_stmm2: __darwin_mmst_reg, + pub __fpu_stmm3: __darwin_mmst_reg, + pub __fpu_stmm4: __darwin_mmst_reg, + pub __fpu_stmm5: __darwin_mmst_reg, + pub __fpu_stmm6: __darwin_mmst_reg, + pub __fpu_stmm7: __darwin_mmst_reg, + pub __fpu_xmm0: __darwin_xmm_reg, + pub __fpu_xmm1: __darwin_xmm_reg, + pub __fpu_xmm2: __darwin_xmm_reg, + pub __fpu_xmm3: __darwin_xmm_reg, + pub __fpu_xmm4: __darwin_xmm_reg, + pub __fpu_xmm5: __darwin_xmm_reg, + pub __fpu_xmm6: __darwin_xmm_reg, + pub __fpu_xmm7: __darwin_xmm_reg, + pub __fpu_rsrv4: [::std::os::raw::c_char; 224usize], + pub __fpu_reserved1: ::std::os::raw::c_int, + pub __avx_reserved1: [::std::os::raw::c_char; 64usize], + pub __fpu_ymmh0: __darwin_xmm_reg, + pub __fpu_ymmh1: __darwin_xmm_reg, + pub __fpu_ymmh2: __darwin_xmm_reg, + pub __fpu_ymmh3: __darwin_xmm_reg, + pub __fpu_ymmh4: __darwin_xmm_reg, + pub __fpu_ymmh5: __darwin_xmm_reg, + pub __fpu_ymmh6: __darwin_xmm_reg, + pub __fpu_ymmh7: __darwin_xmm_reg, +} +#[test] +fn bindgen_test_layout___darwin_i386_avx_state() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_i386_avx_state> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_i386_avx_state>(), + 716usize, + concat!("Size of: ", stringify!(__darwin_i386_avx_state)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_i386_avx_state>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_i386_avx_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fcw) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_fcw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fsw) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_fsw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ftw) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ftw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv1) as usize - ptr as usize }, + 13usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_rsrv1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fop) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_fop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ip) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ip) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_cs) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_cs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv2) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_rsrv2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_dp) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_dp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ds) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ds) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv3) as usize - ptr as usize }, + 30usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_rsrv3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_mxcsr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsrmask) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_mxcsrmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm0) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_stmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm1) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_stmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm2) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_stmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm3) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_stmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm4) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_stmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm5) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_stmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm6) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_stmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm7) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_stmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm0) as usize - ptr as usize }, + 168usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_xmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm1) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_xmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm2) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_xmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm3) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_xmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm4) as usize - ptr as usize }, + 232usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_xmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm5) as usize - ptr as usize }, + 248usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_xmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm6) as usize - ptr as usize }, + 264usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_xmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm7) as usize - ptr as usize }, + 280usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_xmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv4) as usize - ptr as usize }, + 296usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_rsrv4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved1) as usize - ptr as usize }, + 520usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__avx_reserved1) as usize - ptr as usize }, + 524usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__avx_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh0) as usize - ptr as usize }, + 588usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ymmh0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh1) as usize - ptr as usize }, + 604usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ymmh1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh2) as usize - ptr as usize }, + 620usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ymmh2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh3) as usize - ptr as usize }, + 636usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ymmh3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh4) as usize - ptr as usize }, + 652usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ymmh4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh5) as usize - ptr as usize }, + 668usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ymmh5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh6) as usize - ptr as usize }, + 684usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ymmh6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh7) as usize - ptr as usize }, + 700usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx_state), + "::", + stringify!(__fpu_ymmh7) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_i386_avx512_state { + pub __fpu_reserved: [::std::os::raw::c_int; 2usize], + pub __fpu_fcw: __darwin_fp_control, + pub __fpu_fsw: __darwin_fp_status, + pub __fpu_ftw: __uint8_t, + pub __fpu_rsrv1: __uint8_t, + pub __fpu_fop: __uint16_t, + pub __fpu_ip: __uint32_t, + pub __fpu_cs: __uint16_t, + pub __fpu_rsrv2: __uint16_t, + pub __fpu_dp: __uint32_t, + pub __fpu_ds: __uint16_t, + pub __fpu_rsrv3: __uint16_t, + pub __fpu_mxcsr: __uint32_t, + pub __fpu_mxcsrmask: __uint32_t, + pub __fpu_stmm0: __darwin_mmst_reg, + pub __fpu_stmm1: __darwin_mmst_reg, + pub __fpu_stmm2: __darwin_mmst_reg, + pub __fpu_stmm3: __darwin_mmst_reg, + pub __fpu_stmm4: __darwin_mmst_reg, + pub __fpu_stmm5: __darwin_mmst_reg, + pub __fpu_stmm6: __darwin_mmst_reg, + pub __fpu_stmm7: __darwin_mmst_reg, + pub __fpu_xmm0: __darwin_xmm_reg, + pub __fpu_xmm1: __darwin_xmm_reg, + pub __fpu_xmm2: __darwin_xmm_reg, + pub __fpu_xmm3: __darwin_xmm_reg, + pub __fpu_xmm4: __darwin_xmm_reg, + pub __fpu_xmm5: __darwin_xmm_reg, + pub __fpu_xmm6: __darwin_xmm_reg, + pub __fpu_xmm7: __darwin_xmm_reg, + pub __fpu_rsrv4: [::std::os::raw::c_char; 224usize], + pub __fpu_reserved1: ::std::os::raw::c_int, + pub __avx_reserved1: [::std::os::raw::c_char; 64usize], + pub __fpu_ymmh0: __darwin_xmm_reg, + pub __fpu_ymmh1: __darwin_xmm_reg, + pub __fpu_ymmh2: __darwin_xmm_reg, + pub __fpu_ymmh3: __darwin_xmm_reg, + pub __fpu_ymmh4: __darwin_xmm_reg, + pub __fpu_ymmh5: __darwin_xmm_reg, + pub __fpu_ymmh6: __darwin_xmm_reg, + pub __fpu_ymmh7: __darwin_xmm_reg, + pub __fpu_k0: __darwin_opmask_reg, + pub __fpu_k1: __darwin_opmask_reg, + pub __fpu_k2: __darwin_opmask_reg, + pub __fpu_k3: __darwin_opmask_reg, + pub __fpu_k4: __darwin_opmask_reg, + pub __fpu_k5: __darwin_opmask_reg, + pub __fpu_k6: __darwin_opmask_reg, + pub __fpu_k7: __darwin_opmask_reg, + pub __fpu_zmmh0: __darwin_ymm_reg, + pub __fpu_zmmh1: __darwin_ymm_reg, + pub __fpu_zmmh2: __darwin_ymm_reg, + pub __fpu_zmmh3: __darwin_ymm_reg, + pub __fpu_zmmh4: __darwin_ymm_reg, + pub __fpu_zmmh5: __darwin_ymm_reg, + pub __fpu_zmmh6: __darwin_ymm_reg, + pub __fpu_zmmh7: __darwin_ymm_reg, +} +#[test] +fn bindgen_test_layout___darwin_i386_avx512_state() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_i386_avx512_state> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_i386_avx512_state>(), + 1036usize, + concat!("Size of: ", stringify!(__darwin_i386_avx512_state)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_i386_avx512_state>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_i386_avx512_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fcw) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_fcw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fsw) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_fsw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ftw) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ftw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv1) as usize - ptr as usize }, + 13usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_rsrv1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fop) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_fop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ip) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ip) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_cs) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_cs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv2) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_rsrv2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_dp) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_dp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ds) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ds) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv3) as usize - ptr as usize }, + 30usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_rsrv3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_mxcsr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsrmask) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_mxcsrmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm0) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_stmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm1) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_stmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm2) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_stmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm3) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_stmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm4) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_stmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm5) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_stmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm6) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_stmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm7) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_stmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm0) as usize - ptr as usize }, + 168usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_xmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm1) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_xmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm2) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_xmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm3) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_xmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm4) as usize - ptr as usize }, + 232usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_xmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm5) as usize - ptr as usize }, + 248usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_xmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm6) as usize - ptr as usize }, + 264usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_xmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm7) as usize - ptr as usize }, + 280usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_xmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv4) as usize - ptr as usize }, + 296usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_rsrv4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved1) as usize - ptr as usize }, + 520usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__avx_reserved1) as usize - ptr as usize }, + 524usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__avx_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh0) as usize - ptr as usize }, + 588usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ymmh0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh1) as usize - ptr as usize }, + 604usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ymmh1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh2) as usize - ptr as usize }, + 620usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ymmh2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh3) as usize - ptr as usize }, + 636usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ymmh3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh4) as usize - ptr as usize }, + 652usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ymmh4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh5) as usize - ptr as usize }, + 668usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ymmh5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh6) as usize - ptr as usize }, + 684usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ymmh6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh7) as usize - ptr as usize }, + 700usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_ymmh7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k0) as usize - ptr as usize }, + 716usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_k0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k1) as usize - ptr as usize }, + 724usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_k1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k2) as usize - ptr as usize }, + 732usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_k2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k3) as usize - ptr as usize }, + 740usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_k3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k4) as usize - ptr as usize }, + 748usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_k4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k5) as usize - ptr as usize }, + 756usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_k5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k6) as usize - ptr as usize }, + 764usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_k6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k7) as usize - ptr as usize }, + 772usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_k7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh0) as usize - ptr as usize }, + 780usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_zmmh0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh1) as usize - ptr as usize }, + 812usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_zmmh1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh2) as usize - ptr as usize }, + 844usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_zmmh2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh3) as usize - ptr as usize }, + 876usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_zmmh3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh4) as usize - ptr as usize }, + 908usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_zmmh4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh5) as usize - ptr as usize }, + 940usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_zmmh5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh6) as usize - ptr as usize }, + 972usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_zmmh6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh7) as usize - ptr as usize }, + 1004usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_avx512_state), + "::", + stringify!(__fpu_zmmh7) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_i386_exception_state { + pub __trapno: __uint16_t, + pub __cpu: __uint16_t, + pub __err: __uint32_t, + pub __faultvaddr: __uint32_t, +} +#[test] +fn bindgen_test_layout___darwin_i386_exception_state() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_i386_exception_state> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_i386_exception_state>(), + 12usize, + concat!("Size of: ", stringify!(__darwin_i386_exception_state)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_i386_exception_state>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_i386_exception_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__trapno) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_exception_state), + "::", + stringify!(__trapno) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__cpu) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_exception_state), + "::", + stringify!(__cpu) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__err) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_exception_state), + "::", + stringify!(__err) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__faultvaddr) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_i386_exception_state), + "::", + stringify!(__faultvaddr) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_x86_debug_state32 { + pub __dr0: ::std::os::raw::c_uint, + pub __dr1: ::std::os::raw::c_uint, + pub __dr2: ::std::os::raw::c_uint, + pub __dr3: ::std::os::raw::c_uint, + pub __dr4: ::std::os::raw::c_uint, + pub __dr5: ::std::os::raw::c_uint, + pub __dr6: ::std::os::raw::c_uint, + pub __dr7: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout___darwin_x86_debug_state32() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_x86_debug_state32> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_x86_debug_state32>(), + 32usize, + concat!("Size of: ", stringify!(__darwin_x86_debug_state32)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_x86_debug_state32>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_x86_debug_state32)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr0) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state32), + "::", + stringify!(__dr0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr1) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state32), + "::", + stringify!(__dr1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr2) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state32), + "::", + stringify!(__dr2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr3) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state32), + "::", + stringify!(__dr3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr4) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state32), + "::", + stringify!(__dr4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr5) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state32), + "::", + stringify!(__dr5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr6) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state32), + "::", + stringify!(__dr6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr7) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state32), + "::", + stringify!(__dr7) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __x86_instruction_state { + pub __insn_stream_valid_bytes: ::std::os::raw::c_int, + pub __insn_offset: ::std::os::raw::c_int, + pub __out_of_synch: ::std::os::raw::c_int, + pub __insn_bytes: [__uint8_t; 2380usize], + pub __insn_cacheline: [__uint8_t; 64usize], +} +#[test] +fn bindgen_test_layout___x86_instruction_state() { + const UNINIT: ::std::mem::MaybeUninit<__x86_instruction_state> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__x86_instruction_state>(), + 2456usize, + concat!("Size of: ", stringify!(__x86_instruction_state)) + ); + assert_eq!( + ::std::mem::align_of::<__x86_instruction_state>(), + 4usize, + concat!("Alignment of ", stringify!(__x86_instruction_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__insn_stream_valid_bytes) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__x86_instruction_state), + "::", + stringify!(__insn_stream_valid_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__insn_offset) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__x86_instruction_state), + "::", + stringify!(__insn_offset) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__out_of_synch) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__x86_instruction_state), + "::", + stringify!(__out_of_synch) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__insn_bytes) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__x86_instruction_state), + "::", + stringify!(__insn_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__insn_cacheline) as usize - ptr as usize }, + 2392usize, + concat!( + "Offset of field: ", + stringify!(__x86_instruction_state), + "::", + stringify!(__insn_cacheline) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __last_branch_record { + pub __from_ip: __uint64_t, + pub __to_ip: __uint64_t, + pub _bitfield_align_1: [u16; 0], + pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, + pub __bindgen_padding_0: u32, +} +#[test] +fn bindgen_test_layout___last_branch_record() { + const UNINIT: ::std::mem::MaybeUninit<__last_branch_record> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__last_branch_record>(), + 24usize, + concat!("Size of: ", stringify!(__last_branch_record)) + ); + assert_eq!( + ::std::mem::align_of::<__last_branch_record>(), + 8usize, + concat!("Alignment of ", stringify!(__last_branch_record)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__from_ip) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__last_branch_record), + "::", + stringify!(__from_ip) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__to_ip) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__last_branch_record), + "::", + stringify!(__to_ip) + ) + ); +} +impl __last_branch_record { + #[inline] + pub fn __mispredict(&self) -> __uint32_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) } + } + + #[inline] + pub fn set___mispredict(&mut self, val: __uint32_t) { + unsafe { + let val: u32 = ::std::mem::transmute(val); + self._bitfield_1.set(0usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __tsx_abort(&self) -> __uint32_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) } + } + + #[inline] + pub fn set___tsx_abort(&mut self, val: __uint32_t) { + unsafe { + let val: u32 = ::std::mem::transmute(val); + self._bitfield_1.set(1usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __in_tsx(&self) -> __uint32_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u32) } + } + + #[inline] + pub fn set___in_tsx(&mut self, val: __uint32_t) { + unsafe { + let val: u32 = ::std::mem::transmute(val); + self._bitfield_1.set(2usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __cycle_count(&self) -> __uint32_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 16u8) as u32) } + } + + #[inline] + pub fn set___cycle_count(&mut self, val: __uint32_t) { + unsafe { + let val: u32 = ::std::mem::transmute(val); + self._bitfield_1.set(3usize, 16u8, val as u64) + } + } + + #[inline] + pub fn __reserved(&self) -> __uint32_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(19usize, 13u8) as u32) } + } + + #[inline] + pub fn set___reserved(&mut self, val: __uint32_t) { + unsafe { + let val: u32 = ::std::mem::transmute(val); + self._bitfield_1.set(19usize, 13u8, val as u64) + } + } + + #[inline] + pub fn new_bitfield_1( + __mispredict: __uint32_t, + __tsx_abort: __uint32_t, + __in_tsx: __uint32_t, + __cycle_count: __uint32_t, + __reserved: __uint32_t, + ) -> __BindgenBitfieldUnit<[u8; 4usize]> { + let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); + __bindgen_bitfield_unit.set(0usize, 1u8, { + let __mispredict: u32 = unsafe { ::std::mem::transmute(__mispredict) }; + __mispredict as u64 + }); + __bindgen_bitfield_unit.set(1usize, 1u8, { + let __tsx_abort: u32 = unsafe { ::std::mem::transmute(__tsx_abort) }; + __tsx_abort as u64 + }); + __bindgen_bitfield_unit.set(2usize, 1u8, { + let __in_tsx: u32 = unsafe { ::std::mem::transmute(__in_tsx) }; + __in_tsx as u64 + }); + __bindgen_bitfield_unit.set(3usize, 16u8, { + let __cycle_count: u32 = unsafe { ::std::mem::transmute(__cycle_count) }; + __cycle_count as u64 + }); + __bindgen_bitfield_unit.set(19usize, 13u8, { + let __reserved: u32 = unsafe { ::std::mem::transmute(__reserved) }; + __reserved as u64 + }); + __bindgen_bitfield_unit + } +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __last_branch_state { + pub __lbr_count: ::std::os::raw::c_int, + pub _bitfield_align_1: [u32; 0], + pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, + pub __lbrs: [__last_branch_record; 32usize], +} +#[test] +fn bindgen_test_layout___last_branch_state() { + const UNINIT: ::std::mem::MaybeUninit<__last_branch_state> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__last_branch_state>(), + 776usize, + concat!("Size of: ", stringify!(__last_branch_state)) + ); + assert_eq!( + ::std::mem::align_of::<__last_branch_state>(), + 8usize, + concat!("Alignment of ", stringify!(__last_branch_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__lbr_count) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__last_branch_state), + "::", + stringify!(__lbr_count) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__lbrs) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__last_branch_state), + "::", + stringify!(__lbrs) + ) + ); +} +impl __last_branch_state { + #[inline] + pub fn __lbr_supported_tsx(&self) -> __uint32_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) } + } + + #[inline] + pub fn set___lbr_supported_tsx(&mut self, val: __uint32_t) { + unsafe { + let val: u32 = ::std::mem::transmute(val); + self._bitfield_1.set(0usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __lbr_supported_cycle_count(&self) -> __uint32_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) } + } + + #[inline] + pub fn set___lbr_supported_cycle_count(&mut self, val: __uint32_t) { + unsafe { + let val: u32 = ::std::mem::transmute(val); + self._bitfield_1.set(1usize, 1u8, val as u64) + } + } + + #[inline] + pub fn __reserved(&self) -> __uint32_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 30u8) as u32) } + } + + #[inline] + pub fn set___reserved(&mut self, val: __uint32_t) { + unsafe { + let val: u32 = ::std::mem::transmute(val); + self._bitfield_1.set(2usize, 30u8, val as u64) + } + } + + #[inline] + pub fn new_bitfield_1( + __lbr_supported_tsx: __uint32_t, + __lbr_supported_cycle_count: __uint32_t, + __reserved: __uint32_t, + ) -> __BindgenBitfieldUnit<[u8; 4usize]> { + let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); + __bindgen_bitfield_unit.set(0usize, 1u8, { + let __lbr_supported_tsx: u32 = unsafe { ::std::mem::transmute(__lbr_supported_tsx) }; + __lbr_supported_tsx as u64 + }); + __bindgen_bitfield_unit.set(1usize, 1u8, { + let __lbr_supported_cycle_count: u32 = unsafe { ::std::mem::transmute(__lbr_supported_cycle_count) }; + __lbr_supported_cycle_count as u64 + }); + __bindgen_bitfield_unit.set(2usize, 30u8, { + let __reserved: u32 = unsafe { ::std::mem::transmute(__reserved) }; + __reserved as u64 + }); + __bindgen_bitfield_unit + } +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __x86_pagein_state { + pub __pagein_error: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___x86_pagein_state() { + const UNINIT: ::std::mem::MaybeUninit<__x86_pagein_state> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__x86_pagein_state>(), + 4usize, + concat!("Size of: ", stringify!(__x86_pagein_state)) + ); + assert_eq!( + ::std::mem::align_of::<__x86_pagein_state>(), + 4usize, + concat!("Alignment of ", stringify!(__x86_pagein_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__pagein_error) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__x86_pagein_state), + "::", + stringify!(__pagein_error) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_x86_thread_state64 { + pub __rax: __uint64_t, + pub __rbx: __uint64_t, + pub __rcx: __uint64_t, + pub __rdx: __uint64_t, + pub __rdi: __uint64_t, + pub __rsi: __uint64_t, + pub __rbp: __uint64_t, + pub __rsp: __uint64_t, + pub __r8: __uint64_t, + pub __r9: __uint64_t, + pub __r10: __uint64_t, + pub __r11: __uint64_t, + pub __r12: __uint64_t, + pub __r13: __uint64_t, + pub __r14: __uint64_t, + pub __r15: __uint64_t, + pub __rip: __uint64_t, + pub __rflags: __uint64_t, + pub __cs: __uint64_t, + pub __fs: __uint64_t, + pub __gs: __uint64_t, +} +#[test] +fn bindgen_test_layout___darwin_x86_thread_state64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_x86_thread_state64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_x86_thread_state64>(), + 168usize, + concat!("Size of: ", stringify!(__darwin_x86_thread_state64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_x86_thread_state64>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_x86_thread_state64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rax) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rax) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rbx) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rbx) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rcx) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rcx) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rdx) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rdx) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rdi) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rdi) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rsi) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rsi) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rbp) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rbp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rsp) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rsp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__r8) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__r8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__r9) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__r9) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__r10) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__r10) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__r11) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__r11) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__r12) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__r12) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__r13) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__r13) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__r14) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__r14) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__r15) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__r15) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rip) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rip) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__rflags) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__rflags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__cs) as usize - ptr as usize }, + 144usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__cs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__fs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__gs) as usize - ptr as usize }, + 160usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_state64), + "::", + stringify!(__gs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_x86_thread_full_state64 { + pub __ss64: __darwin_x86_thread_state64, + pub __ds: __uint64_t, + pub __es: __uint64_t, + pub __ss: __uint64_t, + pub __gsbase: __uint64_t, +} +#[test] +fn bindgen_test_layout___darwin_x86_thread_full_state64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_x86_thread_full_state64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_x86_thread_full_state64>(), + 200usize, + concat!("Size of: ", stringify!(__darwin_x86_thread_full_state64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_x86_thread_full_state64>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_x86_thread_full_state64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss64) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_full_state64), + "::", + stringify!(__ss64) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ds) as usize - ptr as usize }, + 168usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_full_state64), + "::", + stringify!(__ds) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 176usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_full_state64), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_full_state64), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__gsbase) as usize - ptr as usize }, + 192usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_thread_full_state64), + "::", + stringify!(__gsbase) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_x86_float_state64 { + pub __fpu_reserved: [::std::os::raw::c_int; 2usize], + pub __fpu_fcw: __darwin_fp_control, + pub __fpu_fsw: __darwin_fp_status, + pub __fpu_ftw: __uint8_t, + pub __fpu_rsrv1: __uint8_t, + pub __fpu_fop: __uint16_t, + pub __fpu_ip: __uint32_t, + pub __fpu_cs: __uint16_t, + pub __fpu_rsrv2: __uint16_t, + pub __fpu_dp: __uint32_t, + pub __fpu_ds: __uint16_t, + pub __fpu_rsrv3: __uint16_t, + pub __fpu_mxcsr: __uint32_t, + pub __fpu_mxcsrmask: __uint32_t, + pub __fpu_stmm0: __darwin_mmst_reg, + pub __fpu_stmm1: __darwin_mmst_reg, + pub __fpu_stmm2: __darwin_mmst_reg, + pub __fpu_stmm3: __darwin_mmst_reg, + pub __fpu_stmm4: __darwin_mmst_reg, + pub __fpu_stmm5: __darwin_mmst_reg, + pub __fpu_stmm6: __darwin_mmst_reg, + pub __fpu_stmm7: __darwin_mmst_reg, + pub __fpu_xmm0: __darwin_xmm_reg, + pub __fpu_xmm1: __darwin_xmm_reg, + pub __fpu_xmm2: __darwin_xmm_reg, + pub __fpu_xmm3: __darwin_xmm_reg, + pub __fpu_xmm4: __darwin_xmm_reg, + pub __fpu_xmm5: __darwin_xmm_reg, + pub __fpu_xmm6: __darwin_xmm_reg, + pub __fpu_xmm7: __darwin_xmm_reg, + pub __fpu_xmm8: __darwin_xmm_reg, + pub __fpu_xmm9: __darwin_xmm_reg, + pub __fpu_xmm10: __darwin_xmm_reg, + pub __fpu_xmm11: __darwin_xmm_reg, + pub __fpu_xmm12: __darwin_xmm_reg, + pub __fpu_xmm13: __darwin_xmm_reg, + pub __fpu_xmm14: __darwin_xmm_reg, + pub __fpu_xmm15: __darwin_xmm_reg, + pub __fpu_rsrv4: [::std::os::raw::c_char; 96usize], + pub __fpu_reserved1: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___darwin_x86_float_state64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_x86_float_state64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_x86_float_state64>(), + 524usize, + concat!("Size of: ", stringify!(__darwin_x86_float_state64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_x86_float_state64>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_x86_float_state64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fcw) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_fcw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fsw) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_fsw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ftw) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_ftw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv1) as usize - ptr as usize }, + 13usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_rsrv1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fop) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_fop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ip) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_ip) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_cs) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_cs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv2) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_rsrv2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_dp) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_dp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ds) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_ds) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv3) as usize - ptr as usize }, + 30usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_rsrv3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_mxcsr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsrmask) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_mxcsrmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm0) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_stmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm1) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_stmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm2) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_stmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm3) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_stmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm4) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_stmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm5) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_stmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm6) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_stmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm7) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_stmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm0) as usize - ptr as usize }, + 168usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm1) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm2) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm3) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm4) as usize - ptr as usize }, + 232usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm5) as usize - ptr as usize }, + 248usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm6) as usize - ptr as usize }, + 264usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm7) as usize - ptr as usize }, + 280usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm8) as usize - ptr as usize }, + 296usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm9) as usize - ptr as usize }, + 312usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm9) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm10) as usize - ptr as usize }, + 328usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm10) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm11) as usize - ptr as usize }, + 344usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm11) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm12) as usize - ptr as usize }, + 360usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm12) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm13) as usize - ptr as usize }, + 376usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm13) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm14) as usize - ptr as usize }, + 392usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm14) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm15) as usize - ptr as usize }, + 408usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_xmm15) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv4) as usize - ptr as usize }, + 424usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_rsrv4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved1) as usize - ptr as usize }, + 520usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_float_state64), + "::", + stringify!(__fpu_reserved1) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_x86_avx_state64 { + pub __fpu_reserved: [::std::os::raw::c_int; 2usize], + pub __fpu_fcw: __darwin_fp_control, + pub __fpu_fsw: __darwin_fp_status, + pub __fpu_ftw: __uint8_t, + pub __fpu_rsrv1: __uint8_t, + pub __fpu_fop: __uint16_t, + pub __fpu_ip: __uint32_t, + pub __fpu_cs: __uint16_t, + pub __fpu_rsrv2: __uint16_t, + pub __fpu_dp: __uint32_t, + pub __fpu_ds: __uint16_t, + pub __fpu_rsrv3: __uint16_t, + pub __fpu_mxcsr: __uint32_t, + pub __fpu_mxcsrmask: __uint32_t, + pub __fpu_stmm0: __darwin_mmst_reg, + pub __fpu_stmm1: __darwin_mmst_reg, + pub __fpu_stmm2: __darwin_mmst_reg, + pub __fpu_stmm3: __darwin_mmst_reg, + pub __fpu_stmm4: __darwin_mmst_reg, + pub __fpu_stmm5: __darwin_mmst_reg, + pub __fpu_stmm6: __darwin_mmst_reg, + pub __fpu_stmm7: __darwin_mmst_reg, + pub __fpu_xmm0: __darwin_xmm_reg, + pub __fpu_xmm1: __darwin_xmm_reg, + pub __fpu_xmm2: __darwin_xmm_reg, + pub __fpu_xmm3: __darwin_xmm_reg, + pub __fpu_xmm4: __darwin_xmm_reg, + pub __fpu_xmm5: __darwin_xmm_reg, + pub __fpu_xmm6: __darwin_xmm_reg, + pub __fpu_xmm7: __darwin_xmm_reg, + pub __fpu_xmm8: __darwin_xmm_reg, + pub __fpu_xmm9: __darwin_xmm_reg, + pub __fpu_xmm10: __darwin_xmm_reg, + pub __fpu_xmm11: __darwin_xmm_reg, + pub __fpu_xmm12: __darwin_xmm_reg, + pub __fpu_xmm13: __darwin_xmm_reg, + pub __fpu_xmm14: __darwin_xmm_reg, + pub __fpu_xmm15: __darwin_xmm_reg, + pub __fpu_rsrv4: [::std::os::raw::c_char; 96usize], + pub __fpu_reserved1: ::std::os::raw::c_int, + pub __avx_reserved1: [::std::os::raw::c_char; 64usize], + pub __fpu_ymmh0: __darwin_xmm_reg, + pub __fpu_ymmh1: __darwin_xmm_reg, + pub __fpu_ymmh2: __darwin_xmm_reg, + pub __fpu_ymmh3: __darwin_xmm_reg, + pub __fpu_ymmh4: __darwin_xmm_reg, + pub __fpu_ymmh5: __darwin_xmm_reg, + pub __fpu_ymmh6: __darwin_xmm_reg, + pub __fpu_ymmh7: __darwin_xmm_reg, + pub __fpu_ymmh8: __darwin_xmm_reg, + pub __fpu_ymmh9: __darwin_xmm_reg, + pub __fpu_ymmh10: __darwin_xmm_reg, + pub __fpu_ymmh11: __darwin_xmm_reg, + pub __fpu_ymmh12: __darwin_xmm_reg, + pub __fpu_ymmh13: __darwin_xmm_reg, + pub __fpu_ymmh14: __darwin_xmm_reg, + pub __fpu_ymmh15: __darwin_xmm_reg, +} +#[test] +fn bindgen_test_layout___darwin_x86_avx_state64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_x86_avx_state64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_x86_avx_state64>(), + 844usize, + concat!("Size of: ", stringify!(__darwin_x86_avx_state64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_x86_avx_state64>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_x86_avx_state64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fcw) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_fcw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fsw) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_fsw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ftw) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ftw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv1) as usize - ptr as usize }, + 13usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_rsrv1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fop) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_fop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ip) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ip) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_cs) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_cs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv2) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_rsrv2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_dp) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_dp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ds) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ds) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv3) as usize - ptr as usize }, + 30usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_rsrv3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_mxcsr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsrmask) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_mxcsrmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm0) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_stmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm1) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_stmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm2) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_stmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm3) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_stmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm4) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_stmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm5) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_stmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm6) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_stmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm7) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_stmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm0) as usize - ptr as usize }, + 168usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm1) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm2) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm3) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm4) as usize - ptr as usize }, + 232usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm5) as usize - ptr as usize }, + 248usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm6) as usize - ptr as usize }, + 264usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm7) as usize - ptr as usize }, + 280usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm8) as usize - ptr as usize }, + 296usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm9) as usize - ptr as usize }, + 312usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm9) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm10) as usize - ptr as usize }, + 328usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm10) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm11) as usize - ptr as usize }, + 344usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm11) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm12) as usize - ptr as usize }, + 360usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm12) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm13) as usize - ptr as usize }, + 376usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm13) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm14) as usize - ptr as usize }, + 392usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm14) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm15) as usize - ptr as usize }, + 408usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_xmm15) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv4) as usize - ptr as usize }, + 424usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_rsrv4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved1) as usize - ptr as usize }, + 520usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__avx_reserved1) as usize - ptr as usize }, + 524usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__avx_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh0) as usize - ptr as usize }, + 588usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh1) as usize - ptr as usize }, + 604usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh2) as usize - ptr as usize }, + 620usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh3) as usize - ptr as usize }, + 636usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh4) as usize - ptr as usize }, + 652usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh5) as usize - ptr as usize }, + 668usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh6) as usize - ptr as usize }, + 684usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh7) as usize - ptr as usize }, + 700usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh8) as usize - ptr as usize }, + 716usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh9) as usize - ptr as usize }, + 732usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh9) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh10) as usize - ptr as usize }, + 748usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh10) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh11) as usize - ptr as usize }, + 764usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh11) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh12) as usize - ptr as usize }, + 780usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh12) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh13) as usize - ptr as usize }, + 796usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh13) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh14) as usize - ptr as usize }, + 812usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh14) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh15) as usize - ptr as usize }, + 828usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx_state64), + "::", + stringify!(__fpu_ymmh15) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_x86_avx512_state64 { + pub __fpu_reserved: [::std::os::raw::c_int; 2usize], + pub __fpu_fcw: __darwin_fp_control, + pub __fpu_fsw: __darwin_fp_status, + pub __fpu_ftw: __uint8_t, + pub __fpu_rsrv1: __uint8_t, + pub __fpu_fop: __uint16_t, + pub __fpu_ip: __uint32_t, + pub __fpu_cs: __uint16_t, + pub __fpu_rsrv2: __uint16_t, + pub __fpu_dp: __uint32_t, + pub __fpu_ds: __uint16_t, + pub __fpu_rsrv3: __uint16_t, + pub __fpu_mxcsr: __uint32_t, + pub __fpu_mxcsrmask: __uint32_t, + pub __fpu_stmm0: __darwin_mmst_reg, + pub __fpu_stmm1: __darwin_mmst_reg, + pub __fpu_stmm2: __darwin_mmst_reg, + pub __fpu_stmm3: __darwin_mmst_reg, + pub __fpu_stmm4: __darwin_mmst_reg, + pub __fpu_stmm5: __darwin_mmst_reg, + pub __fpu_stmm6: __darwin_mmst_reg, + pub __fpu_stmm7: __darwin_mmst_reg, + pub __fpu_xmm0: __darwin_xmm_reg, + pub __fpu_xmm1: __darwin_xmm_reg, + pub __fpu_xmm2: __darwin_xmm_reg, + pub __fpu_xmm3: __darwin_xmm_reg, + pub __fpu_xmm4: __darwin_xmm_reg, + pub __fpu_xmm5: __darwin_xmm_reg, + pub __fpu_xmm6: __darwin_xmm_reg, + pub __fpu_xmm7: __darwin_xmm_reg, + pub __fpu_xmm8: __darwin_xmm_reg, + pub __fpu_xmm9: __darwin_xmm_reg, + pub __fpu_xmm10: __darwin_xmm_reg, + pub __fpu_xmm11: __darwin_xmm_reg, + pub __fpu_xmm12: __darwin_xmm_reg, + pub __fpu_xmm13: __darwin_xmm_reg, + pub __fpu_xmm14: __darwin_xmm_reg, + pub __fpu_xmm15: __darwin_xmm_reg, + pub __fpu_rsrv4: [::std::os::raw::c_char; 96usize], + pub __fpu_reserved1: ::std::os::raw::c_int, + pub __avx_reserved1: [::std::os::raw::c_char; 64usize], + pub __fpu_ymmh0: __darwin_xmm_reg, + pub __fpu_ymmh1: __darwin_xmm_reg, + pub __fpu_ymmh2: __darwin_xmm_reg, + pub __fpu_ymmh3: __darwin_xmm_reg, + pub __fpu_ymmh4: __darwin_xmm_reg, + pub __fpu_ymmh5: __darwin_xmm_reg, + pub __fpu_ymmh6: __darwin_xmm_reg, + pub __fpu_ymmh7: __darwin_xmm_reg, + pub __fpu_ymmh8: __darwin_xmm_reg, + pub __fpu_ymmh9: __darwin_xmm_reg, + pub __fpu_ymmh10: __darwin_xmm_reg, + pub __fpu_ymmh11: __darwin_xmm_reg, + pub __fpu_ymmh12: __darwin_xmm_reg, + pub __fpu_ymmh13: __darwin_xmm_reg, + pub __fpu_ymmh14: __darwin_xmm_reg, + pub __fpu_ymmh15: __darwin_xmm_reg, + pub __fpu_k0: __darwin_opmask_reg, + pub __fpu_k1: __darwin_opmask_reg, + pub __fpu_k2: __darwin_opmask_reg, + pub __fpu_k3: __darwin_opmask_reg, + pub __fpu_k4: __darwin_opmask_reg, + pub __fpu_k5: __darwin_opmask_reg, + pub __fpu_k6: __darwin_opmask_reg, + pub __fpu_k7: __darwin_opmask_reg, + pub __fpu_zmmh0: __darwin_ymm_reg, + pub __fpu_zmmh1: __darwin_ymm_reg, + pub __fpu_zmmh2: __darwin_ymm_reg, + pub __fpu_zmmh3: __darwin_ymm_reg, + pub __fpu_zmmh4: __darwin_ymm_reg, + pub __fpu_zmmh5: __darwin_ymm_reg, + pub __fpu_zmmh6: __darwin_ymm_reg, + pub __fpu_zmmh7: __darwin_ymm_reg, + pub __fpu_zmmh8: __darwin_ymm_reg, + pub __fpu_zmmh9: __darwin_ymm_reg, + pub __fpu_zmmh10: __darwin_ymm_reg, + pub __fpu_zmmh11: __darwin_ymm_reg, + pub __fpu_zmmh12: __darwin_ymm_reg, + pub __fpu_zmmh13: __darwin_ymm_reg, + pub __fpu_zmmh14: __darwin_ymm_reg, + pub __fpu_zmmh15: __darwin_ymm_reg, + pub __fpu_zmm16: __darwin_zmm_reg, + pub __fpu_zmm17: __darwin_zmm_reg, + pub __fpu_zmm18: __darwin_zmm_reg, + pub __fpu_zmm19: __darwin_zmm_reg, + pub __fpu_zmm20: __darwin_zmm_reg, + pub __fpu_zmm21: __darwin_zmm_reg, + pub __fpu_zmm22: __darwin_zmm_reg, + pub __fpu_zmm23: __darwin_zmm_reg, + pub __fpu_zmm24: __darwin_zmm_reg, + pub __fpu_zmm25: __darwin_zmm_reg, + pub __fpu_zmm26: __darwin_zmm_reg, + pub __fpu_zmm27: __darwin_zmm_reg, + pub __fpu_zmm28: __darwin_zmm_reg, + pub __fpu_zmm29: __darwin_zmm_reg, + pub __fpu_zmm30: __darwin_zmm_reg, + pub __fpu_zmm31: __darwin_zmm_reg, +} +#[test] +fn bindgen_test_layout___darwin_x86_avx512_state64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_x86_avx512_state64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_x86_avx512_state64>(), + 2444usize, + concat!("Size of: ", stringify!(__darwin_x86_avx512_state64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_x86_avx512_state64>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_x86_avx512_state64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fcw) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_fcw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fsw) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_fsw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ftw) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ftw) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv1) as usize - ptr as usize }, + 13usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_rsrv1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_fop) as usize - ptr as usize }, + 14usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_fop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ip) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ip) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_cs) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_cs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv2) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_rsrv2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_dp) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_dp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ds) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ds) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv3) as usize - ptr as usize }, + 30usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_rsrv3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_mxcsr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_mxcsrmask) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_mxcsrmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm0) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_stmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm1) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_stmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm2) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_stmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm3) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_stmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm4) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_stmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm5) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_stmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm6) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_stmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_stmm7) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_stmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm0) as usize - ptr as usize }, + 168usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm1) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm2) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm3) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm4) as usize - ptr as usize }, + 232usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm5) as usize - ptr as usize }, + 248usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm6) as usize - ptr as usize }, + 264usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm7) as usize - ptr as usize }, + 280usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm8) as usize - ptr as usize }, + 296usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm9) as usize - ptr as usize }, + 312usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm9) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm10) as usize - ptr as usize }, + 328usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm10) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm11) as usize - ptr as usize }, + 344usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm11) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm12) as usize - ptr as usize }, + 360usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm12) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm13) as usize - ptr as usize }, + 376usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm13) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm14) as usize - ptr as usize }, + 392usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm14) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_xmm15) as usize - ptr as usize }, + 408usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_xmm15) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_rsrv4) as usize - ptr as usize }, + 424usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_rsrv4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_reserved1) as usize - ptr as usize }, + 520usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__avx_reserved1) as usize - ptr as usize }, + 524usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__avx_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh0) as usize - ptr as usize }, + 588usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh1) as usize - ptr as usize }, + 604usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh2) as usize - ptr as usize }, + 620usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh3) as usize - ptr as usize }, + 636usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh4) as usize - ptr as usize }, + 652usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh5) as usize - ptr as usize }, + 668usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh6) as usize - ptr as usize }, + 684usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh7) as usize - ptr as usize }, + 700usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh8) as usize - ptr as usize }, + 716usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh9) as usize - ptr as usize }, + 732usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh9) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh10) as usize - ptr as usize }, + 748usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh10) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh11) as usize - ptr as usize }, + 764usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh11) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh12) as usize - ptr as usize }, + 780usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh12) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh13) as usize - ptr as usize }, + 796usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh13) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh14) as usize - ptr as usize }, + 812usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh14) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_ymmh15) as usize - ptr as usize }, + 828usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_ymmh15) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k0) as usize - ptr as usize }, + 844usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_k0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k1) as usize - ptr as usize }, + 852usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_k1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k2) as usize - ptr as usize }, + 860usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_k2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k3) as usize - ptr as usize }, + 868usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_k3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k4) as usize - ptr as usize }, + 876usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_k4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k5) as usize - ptr as usize }, + 884usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_k5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k6) as usize - ptr as usize }, + 892usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_k6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_k7) as usize - ptr as usize }, + 900usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_k7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh0) as usize - ptr as usize }, + 908usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh1) as usize - ptr as usize }, + 940usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh2) as usize - ptr as usize }, + 972usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh3) as usize - ptr as usize }, + 1004usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh4) as usize - ptr as usize }, + 1036usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh5) as usize - ptr as usize }, + 1068usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh6) as usize - ptr as usize }, + 1100usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh7) as usize - ptr as usize }, + 1132usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh7) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh8) as usize - ptr as usize }, + 1164usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh9) as usize - ptr as usize }, + 1196usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh9) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh10) as usize - ptr as usize }, + 1228usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh10) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh11) as usize - ptr as usize }, + 1260usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh11) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh12) as usize - ptr as usize }, + 1292usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh12) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh13) as usize - ptr as usize }, + 1324usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh13) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh14) as usize - ptr as usize }, + 1356usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh14) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmmh15) as usize - ptr as usize }, + 1388usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmmh15) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm16) as usize - ptr as usize }, + 1420usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm17) as usize - ptr as usize }, + 1484usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm17) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm18) as usize - ptr as usize }, + 1548usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm18) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm19) as usize - ptr as usize }, + 1612usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm19) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm20) as usize - ptr as usize }, + 1676usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm20) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm21) as usize - ptr as usize }, + 1740usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm21) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm22) as usize - ptr as usize }, + 1804usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm22) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm23) as usize - ptr as usize }, + 1868usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm23) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm24) as usize - ptr as usize }, + 1932usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm24) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm25) as usize - ptr as usize }, + 1996usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm25) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm26) as usize - ptr as usize }, + 2060usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm26) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm27) as usize - ptr as usize }, + 2124usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm27) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm28) as usize - ptr as usize }, + 2188usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm28) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm29) as usize - ptr as usize }, + 2252usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm29) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm30) as usize - ptr as usize }, + 2316usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm30) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fpu_zmm31) as usize - ptr as usize }, + 2380usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_avx512_state64), + "::", + stringify!(__fpu_zmm31) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_x86_exception_state64 { + pub __trapno: __uint16_t, + pub __cpu: __uint16_t, + pub __err: __uint32_t, + pub __faultvaddr: __uint64_t, +} +#[test] +fn bindgen_test_layout___darwin_x86_exception_state64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_x86_exception_state64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_x86_exception_state64>(), + 16usize, + concat!("Size of: ", stringify!(__darwin_x86_exception_state64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_x86_exception_state64>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_x86_exception_state64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__trapno) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_exception_state64), + "::", + stringify!(__trapno) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__cpu) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_exception_state64), + "::", + stringify!(__cpu) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__err) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_exception_state64), + "::", + stringify!(__err) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__faultvaddr) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_exception_state64), + "::", + stringify!(__faultvaddr) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_x86_debug_state64 { + pub __dr0: __uint64_t, + pub __dr1: __uint64_t, + pub __dr2: __uint64_t, + pub __dr3: __uint64_t, + pub __dr4: __uint64_t, + pub __dr5: __uint64_t, + pub __dr6: __uint64_t, + pub __dr7: __uint64_t, +} +#[test] +fn bindgen_test_layout___darwin_x86_debug_state64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_x86_debug_state64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_x86_debug_state64>(), + 64usize, + concat!("Size of: ", stringify!(__darwin_x86_debug_state64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_x86_debug_state64>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_x86_debug_state64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr0) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state64), + "::", + stringify!(__dr0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr1) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state64), + "::", + stringify!(__dr1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr2) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state64), + "::", + stringify!(__dr2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr3) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state64), + "::", + stringify!(__dr3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr4) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state64), + "::", + stringify!(__dr4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr5) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state64), + "::", + stringify!(__dr5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr6) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state64), + "::", + stringify!(__dr6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__dr7) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_debug_state64), + "::", + stringify!(__dr7) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_x86_cpmu_state64 { + pub __ctrs: [__uint64_t; 16usize], +} +#[test] +fn bindgen_test_layout___darwin_x86_cpmu_state64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_x86_cpmu_state64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_x86_cpmu_state64>(), + 128usize, + concat!("Size of: ", stringify!(__darwin_x86_cpmu_state64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_x86_cpmu_state64>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_x86_cpmu_state64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ctrs) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_x86_cpmu_state64), + "::", + stringify!(__ctrs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mcontext32 { + pub __es: __darwin_i386_exception_state, + pub __ss: __darwin_i386_thread_state, + pub __fs: __darwin_i386_float_state, +} +#[test] +fn bindgen_test_layout___darwin_mcontext32() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mcontext32> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mcontext32>(), + 600usize, + concat!("Size of: ", stringify!(__darwin_mcontext32)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mcontext32>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_mcontext32)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext32), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext32), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 76usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext32), + "::", + stringify!(__fs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mcontext_avx32 { + pub __es: __darwin_i386_exception_state, + pub __ss: __darwin_i386_thread_state, + pub __fs: __darwin_i386_avx_state, +} +#[test] +fn bindgen_test_layout___darwin_mcontext_avx32() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mcontext_avx32> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mcontext_avx32>(), + 792usize, + concat!("Size of: ", stringify!(__darwin_mcontext_avx32)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mcontext_avx32>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_mcontext_avx32)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx32), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx32), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 76usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx32), + "::", + stringify!(__fs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mcontext_avx512_32 { + pub __es: __darwin_i386_exception_state, + pub __ss: __darwin_i386_thread_state, + pub __fs: __darwin_i386_avx512_state, +} +#[test] +fn bindgen_test_layout___darwin_mcontext_avx512_32() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mcontext_avx512_32> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mcontext_avx512_32>(), + 1112usize, + concat!("Size of: ", stringify!(__darwin_mcontext_avx512_32)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mcontext_avx512_32>(), + 4usize, + concat!("Alignment of ", stringify!(__darwin_mcontext_avx512_32)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx512_32), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx512_32), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 76usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx512_32), + "::", + stringify!(__fs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mcontext64 { + pub __es: __darwin_x86_exception_state64, + pub __ss: __darwin_x86_thread_state64, + pub __fs: __darwin_x86_float_state64, +} +#[test] +fn bindgen_test_layout___darwin_mcontext64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mcontext64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mcontext64>(), + 712usize, + concat!("Size of: ", stringify!(__darwin_mcontext64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mcontext64>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_mcontext64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext64), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext64), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext64), + "::", + stringify!(__fs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mcontext64_full { + pub __es: __darwin_x86_exception_state64, + pub __ss: __darwin_x86_thread_full_state64, + pub __fs: __darwin_x86_float_state64, +} +#[test] +fn bindgen_test_layout___darwin_mcontext64_full() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mcontext64_full> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mcontext64_full>(), + 744usize, + concat!("Size of: ", stringify!(__darwin_mcontext64_full)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mcontext64_full>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_mcontext64_full)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext64_full), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext64_full), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext64_full), + "::", + stringify!(__fs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mcontext_avx64 { + pub __es: __darwin_x86_exception_state64, + pub __ss: __darwin_x86_thread_state64, + pub __fs: __darwin_x86_avx_state64, +} +#[test] +fn bindgen_test_layout___darwin_mcontext_avx64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mcontext_avx64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mcontext_avx64>(), + 1032usize, + concat!("Size of: ", stringify!(__darwin_mcontext_avx64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mcontext_avx64>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_mcontext_avx64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx64), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx64), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx64), + "::", + stringify!(__fs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mcontext_avx64_full { + pub __es: __darwin_x86_exception_state64, + pub __ss: __darwin_x86_thread_full_state64, + pub __fs: __darwin_x86_avx_state64, +} +#[test] +fn bindgen_test_layout___darwin_mcontext_avx64_full() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mcontext_avx64_full> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mcontext_avx64_full>(), + 1064usize, + concat!("Size of: ", stringify!(__darwin_mcontext_avx64_full)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mcontext_avx64_full>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_mcontext_avx64_full)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx64_full), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx64_full), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx64_full), + "::", + stringify!(__fs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mcontext_avx512_64 { + pub __es: __darwin_x86_exception_state64, + pub __ss: __darwin_x86_thread_state64, + pub __fs: __darwin_x86_avx512_state64, +} +#[test] +fn bindgen_test_layout___darwin_mcontext_avx512_64() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mcontext_avx512_64> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mcontext_avx512_64>(), + 2632usize, + concat!("Size of: ", stringify!(__darwin_mcontext_avx512_64)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mcontext_avx512_64>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_mcontext_avx512_64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx512_64), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx512_64), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx512_64), + "::", + stringify!(__fs) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_mcontext_avx512_64_full { + pub __es: __darwin_x86_exception_state64, + pub __ss: __darwin_x86_thread_full_state64, + pub __fs: __darwin_x86_avx512_state64, +} +#[test] +fn bindgen_test_layout___darwin_mcontext_avx512_64_full() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_mcontext_avx512_64_full> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_mcontext_avx512_64_full>(), + 2664usize, + concat!("Size of: ", stringify!(__darwin_mcontext_avx512_64_full)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_mcontext_avx512_64_full>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_mcontext_avx512_64_full)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__es) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx512_64_full), + "::", + stringify!(__es) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx512_64_full), + "::", + stringify!(__ss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__fs) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(__darwin_mcontext_avx512_64_full), + "::", + stringify!(__fs) + ) + ); +} +pub type mcontext_t = *mut __darwin_mcontext64; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_sigaltstack { + pub ss_sp: *mut ::std::os::raw::c_void, + pub ss_size: __darwin_size_t, + pub ss_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___darwin_sigaltstack() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_sigaltstack> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_sigaltstack>(), + 24usize, + concat!("Size of: ", stringify!(__darwin_sigaltstack)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_sigaltstack>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_sigaltstack)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_sp) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_sigaltstack), + "::", + stringify!(ss_sp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_size) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_sigaltstack), + "::", + stringify!(ss_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_flags) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__darwin_sigaltstack), + "::", + stringify!(ss_flags) + ) + ); +} +pub type stack_t = __darwin_sigaltstack; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __darwin_ucontext { + pub uc_onstack: ::std::os::raw::c_int, + pub uc_sigmask: __darwin_sigset_t, + pub uc_stack: __darwin_sigaltstack, + pub uc_link: *mut __darwin_ucontext, + pub uc_mcsize: __darwin_size_t, + pub uc_mcontext: *mut __darwin_mcontext64, +} +#[test] +fn bindgen_test_layout___darwin_ucontext() { + const UNINIT: ::std::mem::MaybeUninit<__darwin_ucontext> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__darwin_ucontext>(), + 56usize, + concat!("Size of: ", stringify!(__darwin_ucontext)) + ); + assert_eq!( + ::std::mem::align_of::<__darwin_ucontext>(), + 8usize, + concat!("Alignment of ", stringify!(__darwin_ucontext)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uc_onstack) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__darwin_ucontext), + "::", + stringify!(uc_onstack) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uc_sigmask) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__darwin_ucontext), + "::", + stringify!(uc_sigmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uc_stack) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__darwin_ucontext), + "::", + stringify!(uc_stack) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uc_link) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__darwin_ucontext), + "::", + stringify!(uc_link) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uc_mcsize) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__darwin_ucontext), + "::", + stringify!(uc_mcsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uc_mcontext) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(__darwin_ucontext), + "::", + stringify!(uc_mcontext) + ) + ); +} +pub type ucontext_t = __darwin_ucontext; +pub type sigset_t = __darwin_sigset_t; +#[repr(C)] +#[derive(Copy, Clone)] +pub union sigval { + pub sival_int: ::std::os::raw::c_int, + pub sival_ptr: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout_sigval() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(sigval)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigval)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sival_int) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigval), "::", stringify!(sival_int)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sival_ptr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigval), "::", stringify!(sival_ptr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct sigevent { + pub sigev_notify: ::std::os::raw::c_int, + pub sigev_signo: ::std::os::raw::c_int, + pub sigev_value: sigval, + pub sigev_notify_function: ::std::option::Option, + pub sigev_notify_attributes: *mut pthread_attr_t, +} +#[test] +fn bindgen_test_layout_sigevent() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(sigevent)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigevent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigev_notify) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigevent), + "::", + stringify!(sigev_notify) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigev_signo) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(sigevent), "::", stringify!(sigev_signo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigev_value) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sigevent), "::", stringify!(sigev_value)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigev_notify_function) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(sigevent), + "::", + stringify!(sigev_notify_function) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sigev_notify_attributes) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(sigevent), + "::", + stringify!(sigev_notify_attributes) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct __siginfo { + pub si_signo: ::std::os::raw::c_int, + pub si_errno: ::std::os::raw::c_int, + pub si_code: ::std::os::raw::c_int, + pub si_pid: pid_t, + pub si_uid: uid_t, + pub si_status: ::std::os::raw::c_int, + pub si_addr: *mut ::std::os::raw::c_void, + pub si_value: sigval, + pub si_band: ::std::os::raw::c_long, + pub __pad: [::std::os::raw::c_ulong; 7usize], +} +#[test] +fn bindgen_test_layout___siginfo() { + const UNINIT: ::std::mem::MaybeUninit<__siginfo> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__siginfo>(), + 104usize, + concat!("Size of: ", stringify!(__siginfo)) + ); + assert_eq!( + ::std::mem::align_of::<__siginfo>(), + 8usize, + concat!("Alignment of ", stringify!(__siginfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_signo) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_signo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_errno) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_errno)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_code) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_code)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_pid) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_pid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_uid) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_status) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_status)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_addr) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_value) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_value)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).si_band) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(si_band)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__pad) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(__siginfo), "::", stringify!(__pad)) + ); +} +pub type siginfo_t = __siginfo; +#[repr(C)] +#[derive(Copy, Clone)] +pub union __sigaction_u { + pub __sa_handler: ::std::option::Option, + pub __sa_sigaction: ::std::option::Option< + unsafe extern "C" fn(arg1: ::std::os::raw::c_int, arg2: *mut __siginfo, arg3: *mut ::std::os::raw::c_void), + >, +} +#[test] +fn bindgen_test_layout___sigaction_u() { + const UNINIT: ::std::mem::MaybeUninit<__sigaction_u> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__sigaction_u>(), + 8usize, + concat!("Size of: ", stringify!(__sigaction_u)) + ); + assert_eq!( + ::std::mem::align_of::<__sigaction_u>(), + 8usize, + concat!("Alignment of ", stringify!(__sigaction_u)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sa_handler) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__sigaction_u), + "::", + stringify!(__sa_handler) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sa_sigaction) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__sigaction_u), + "::", + stringify!(__sa_sigaction) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct __sigaction { + pub __sigaction_u: __sigaction_u, + pub sa_tramp: ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *mut siginfo_t, + arg5: *mut ::std::os::raw::c_void, + ), + >, + pub sa_mask: sigset_t, + pub sa_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout___sigaction() { + const UNINIT: ::std::mem::MaybeUninit<__sigaction> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__sigaction>(), + 24usize, + concat!("Size of: ", stringify!(__sigaction)) + ); + assert_eq!( + ::std::mem::align_of::<__sigaction>(), + 8usize, + concat!("Alignment of ", stringify!(__sigaction)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sigaction_u) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__sigaction), + "::", + stringify!(__sigaction_u) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_tramp) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(__sigaction), "::", stringify!(sa_tramp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_mask) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(__sigaction), "::", stringify!(sa_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_flags) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(__sigaction), "::", stringify!(sa_flags)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct sigaction { + pub __sigaction_u: __sigaction_u, + pub sa_mask: sigset_t, + pub sa_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_sigaction() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sigaction)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigaction)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__sigaction_u) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sigaction), + "::", + stringify!(__sigaction_u) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_mask) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sigaction), "::", stringify!(sa_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_flags) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(sigaction), "::", stringify!(sa_flags)) + ); +} +pub type sig_t = ::std::option::Option; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sigvec { + pub sv_handler: ::std::option::Option, + pub sv_mask: ::std::os::raw::c_int, + pub sv_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_sigvec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sigvec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigvec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sv_handler) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigvec), "::", stringify!(sv_handler)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sv_mask) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sigvec), "::", stringify!(sv_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sv_flags) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(sigvec), "::", stringify!(sv_flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sigstack { + pub ss_sp: *mut ::std::os::raw::c_char, + pub ss_onstack: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_sigstack() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sigstack)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sigstack)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_sp) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sigstack), "::", stringify!(ss_sp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_onstack) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sigstack), "::", stringify!(ss_onstack)) + ); +} +extern "C" { + pub fn signal( + arg1: ::std::os::raw::c_int, + arg2: ::std::option::Option, + ) -> ::std::option::Option< + unsafe extern "C" fn( + arg1: ::std::os::raw::c_int, + arg2: ::std::option::Option, + ), + >; +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_node { + pub rn_mklist: *mut radix_mask, + pub rn_parent: *mut radix_node, + pub rn_bit: ::std::os::raw::c_short, + pub rn_bmask: ::std::os::raw::c_char, + pub rn_flags: u_char, + pub rn_u: radix_node__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union radix_node__bindgen_ty_1 { + pub rn_leaf: radix_node__bindgen_ty_1__bindgen_ty_1, + pub rn_node: radix_node__bindgen_ty_1__bindgen_ty_2, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct radix_node__bindgen_ty_1__bindgen_ty_1 { + pub rn_Key: caddr_t, + pub rn_Mask: caddr_t, + pub rn_Dupedkey: *mut radix_node, +} +#[test] +fn bindgen_test_layout_radix_node__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Key) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rn_Key) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Mask) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rn_Mask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Dupedkey) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rn_Dupedkey) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct radix_node__bindgen_ty_1__bindgen_ty_2 { + pub rn_Off: ::std::os::raw::c_int, + pub rn_L: *mut radix_node, + pub rn_R: *mut radix_node, +} +#[test] +fn bindgen_test_layout_radix_node__bindgen_ty_1__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Off) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(rn_Off) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_L) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(rn_L) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_R) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(rn_R) + ) + ); +} +#[test] +fn bindgen_test_layout_radix_node__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(radix_node__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_leaf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1), + "::", + stringify!(rn_leaf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_node) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1), + "::", + stringify!(rn_node) + ) + ); +} +#[test] +fn bindgen_test_layout_radix_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(radix_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_mklist) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_mklist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_parent) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_bit) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_bit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_bmask) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_bmask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_flags) as usize - ptr as usize }, + 19usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_u) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_u)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_mask { + pub rm_bit: ::std::os::raw::c_short, + pub rm_unused: ::std::os::raw::c_char, + pub rm_flags: u_char, + pub rm_mklist: *mut radix_mask, + pub rm_rmu: radix_mask__bindgen_ty_1, + pub rm_refs: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union radix_mask__bindgen_ty_1 { + pub rmu_mask: caddr_t, + pub rmu_leaf: *mut radix_node, +} +#[test] +fn bindgen_test_layout_radix_mask__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(radix_mask__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_mask__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmu_mask) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_mask__bindgen_ty_1), + "::", + stringify!(rmu_mask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmu_leaf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_mask__bindgen_ty_1), + "::", + stringify!(rmu_leaf) + ) + ); +} +#[test] +fn bindgen_test_layout_radix_mask() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(radix_mask)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_bit) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_bit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_unused) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_unused)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_flags) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_mklist) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_mklist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_rmu) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_rmu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_refs) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_refs)) + ); +} +pub type walktree_f_t = ::std::option::Option< + unsafe extern "C" fn(arg1: *mut radix_node, arg2: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int, +>; +pub type rn_matchf_t = ::std::option::Option< + unsafe extern "C" fn(arg1: *mut radix_node, arg2: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int, +>; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_node_head { + pub rnh_treetop: *mut radix_node, + pub rnh_addrsize: ::std::os::raw::c_int, + pub rnh_pktsize: ::std::os::raw::c_int, + pub rnh_addaddr: ::std::option::Option< + unsafe extern "C" fn( + v: *mut ::std::os::raw::c_void, + mask: *mut ::std::os::raw::c_void, + head: *mut radix_node_head, + nodes: *mut radix_node, + ) -> *mut radix_node, + >, + pub rnh_addpkt: ::std::option::Option< + unsafe extern "C" fn( + v: *mut ::std::os::raw::c_void, + mask: *mut ::std::os::raw::c_void, + head: *mut radix_node_head, + nodes: *mut radix_node, + ) -> *mut radix_node, + >, + pub rnh_deladdr: ::std::option::Option< + unsafe extern "C" fn( + v: *mut ::std::os::raw::c_void, + mask: *mut ::std::os::raw::c_void, + head: *mut radix_node_head, + ) -> *mut radix_node, + >, + pub rnh_delpkt: ::std::option::Option< + unsafe extern "C" fn( + v: *mut ::std::os::raw::c_void, + mask: *mut ::std::os::raw::c_void, + head: *mut radix_node_head, + ) -> *mut radix_node, + >, + pub rnh_matchaddr: ::std::option::Option< + unsafe extern "C" fn(v: *mut ::std::os::raw::c_void, head: *mut radix_node_head) -> *mut radix_node, + >, + pub rnh_matchaddr_args: ::std::option::Option< + unsafe extern "C" fn( + v: *mut ::std::os::raw::c_void, + head: *mut radix_node_head, + f: rn_matchf_t, + w: *mut ::std::os::raw::c_void, + ) -> *mut radix_node, + >, + pub rnh_lookup: ::std::option::Option< + unsafe extern "C" fn( + v: *mut ::std::os::raw::c_void, + mask: *mut ::std::os::raw::c_void, + head: *mut radix_node_head, + ) -> *mut radix_node, + >, + pub rnh_lookup_args: ::std::option::Option< + unsafe extern "C" fn( + v: *mut ::std::os::raw::c_void, + mask: *mut ::std::os::raw::c_void, + head: *mut radix_node_head, + f: rn_matchf_t, + arg1: *mut ::std::os::raw::c_void, + ) -> *mut radix_node, + >, + pub rnh_matchpkt: ::std::option::Option< + unsafe extern "C" fn(v: *mut ::std::os::raw::c_void, head: *mut radix_node_head) -> *mut radix_node, + >, + pub rnh_walktree: ::std::option::Option< + unsafe extern "C" fn( + head: *mut radix_node_head, + f: walktree_f_t, + w: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int, + >, + pub rnh_walktree_from: ::std::option::Option< + unsafe extern "C" fn( + head: *mut radix_node_head, + a: *mut ::std::os::raw::c_void, + m: *mut ::std::os::raw::c_void, + f: walktree_f_t, + w: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int, + >, + pub rnh_close: ::std::option::Option, + pub rnh_nodes: [radix_node; 3usize], + pub rnh_cnt: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_radix_node_head() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 264usize, + concat!("Size of: ", stringify!(radix_node_head)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node_head)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_treetop) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_treetop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_addrsize) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_addrsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_pktsize) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_pktsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_addaddr) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_addaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_addpkt) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_addpkt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_deladdr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_deladdr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_delpkt) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_delpkt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_matchaddr) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_matchaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_matchaddr_args) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_matchaddr_args) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_lookup) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_lookup) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_lookup_args) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_lookup_args) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_matchpkt) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_matchpkt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_walktree) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_walktree) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_walktree_from) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_walktree_from) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_close) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_close) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_nodes) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_nodes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_cnt) as usize - ptr as usize }, + 256usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_cnt) + ) + ); +} +extern "C" { + pub fn rn_init(); +} +extern "C" { + pub fn rn_inithead(arg1: *mut *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rn_refines(arg1: *mut ::std::os::raw::c_void, arg2: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rn_addmask( + arg1: *mut ::std::os::raw::c_void, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_addroute( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_void, + arg3: *mut radix_node_head, + arg4: *mut radix_node, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_delete( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_void, + arg3: *mut radix_node_head, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_lookup( + v_arg: *mut ::std::os::raw::c_void, + m_arg: *mut ::std::os::raw::c_void, + head: *mut radix_node_head, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_lookup_args( + v_arg: *mut ::std::os::raw::c_void, + m_arg: *mut ::std::os::raw::c_void, + head: *mut radix_node_head, + arg1: rn_matchf_t, + arg2: *mut ::std::os::raw::c_void, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_match(arg1: *mut ::std::os::raw::c_void, arg2: *mut radix_node_head) -> *mut radix_node; +} +extern "C" { + pub fn rn_match_args( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut radix_node_head, + arg3: rn_matchf_t, + arg4: *mut ::std::os::raw::c_void, + ) -> *mut radix_node; +} +pub type int_least8_t = i8; +pub type int_least16_t = i16; +pub type int_least32_t = i32; +pub type int_least64_t = i64; +pub type uint_least8_t = u8; +pub type uint_least16_t = u16; +pub type uint_least32_t = u32; +pub type uint_least64_t = u64; +pub type int_fast8_t = i8; +pub type int_fast16_t = i16; +pub type int_fast32_t = i32; +pub type int_fast64_t = i64; +pub type uint_fast8_t = u8; +pub type uint_fast16_t = u16; +pub type uint_fast32_t = u32; +pub type uint_fast64_t = u64; +pub type intmax_t = ::std::os::raw::c_long; +pub type uintmax_t = ::std::os::raw::c_ulong; +pub type uuid_t = __darwin_uuid_t; +pub type uuid_string_t = __darwin_uuid_string_t; +extern "C" { + pub static UUID_NULL: uuid_t; +} +extern "C" { + pub fn uuid_clear(uu: *mut ::std::os::raw::c_uchar); +} +extern "C" { + pub fn uuid_compare(uu1: *mut ::std::os::raw::c_uchar, uu2: *mut ::std::os::raw::c_uchar) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn uuid_copy(dst: *mut ::std::os::raw::c_uchar, src: *mut ::std::os::raw::c_uchar); +} +extern "C" { + pub fn uuid_generate(out: *mut ::std::os::raw::c_uchar); +} +extern "C" { + pub fn uuid_generate_random(out: *mut ::std::os::raw::c_uchar); +} +extern "C" { + pub fn uuid_generate_time(out: *mut ::std::os::raw::c_uchar); +} +extern "C" { + pub fn uuid_generate_early_random(out: *mut ::std::os::raw::c_uchar); +} +extern "C" { + pub fn uuid_is_null(uu: *mut ::std::os::raw::c_uchar) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn uuid_parse(in_: *mut ::std::os::raw::c_char, uu: *mut ::std::os::raw::c_uchar) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn uuid_unparse(uu: *mut ::std::os::raw::c_uchar, out: *mut ::std::os::raw::c_char); +} +extern "C" { + pub fn uuid_unparse_lower(uu: *mut ::std::os::raw::c_uchar, out: *mut ::std::os::raw::c_char); +} +extern "C" { + pub fn uuid_unparse_upper(uu: *mut ::std::os::raw::c_uchar, out: *mut ::std::os::raw::c_char); +} +pub type sa_family_t = __uint8_t; +pub type socklen_t = __darwin_socklen_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct iovec { + pub iov_base: *mut ::std::os::raw::c_void, + pub iov_len: usize, +} +#[test] +fn bindgen_test_layout_iovec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(iovec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(iovec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iov_base) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(iovec), "::", stringify!(iov_base)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iov_len) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(iovec), "::", stringify!(iov_len)) + ); +} +extern "C" { + pub static sotc_by_netservicetype: [::std::os::raw::c_int; 9usize]; +} +pub type sae_associd_t = __uint32_t; +pub type sae_connid_t = __uint32_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sa_endpoints { + pub sae_srcif: ::std::os::raw::c_uint, + pub sae_srcaddr: *const sockaddr, + pub sae_srcaddrlen: socklen_t, + pub sae_dstaddr: *const sockaddr, + pub sae_dstaddrlen: socklen_t, +} +#[test] +fn bindgen_test_layout_sa_endpoints() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(sa_endpoints)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sa_endpoints)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sae_srcif) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sa_endpoints), + "::", + stringify!(sae_srcif) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sae_srcaddr) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sa_endpoints), + "::", + stringify!(sae_srcaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sae_srcaddrlen) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(sa_endpoints), + "::", + stringify!(sae_srcaddrlen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sae_dstaddr) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(sa_endpoints), + "::", + stringify!(sae_dstaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sae_dstaddrlen) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(sa_endpoints), + "::", + stringify!(sae_dstaddrlen) + ) + ); +} +pub type sa_endpoints_t = sa_endpoints; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct linger { + pub l_onoff: ::std::os::raw::c_int, + pub l_linger: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_linger() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(linger)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(linger)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).l_onoff) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(linger), "::", stringify!(l_onoff)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).l_linger) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(linger), "::", stringify!(l_linger)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct so_np_extensions { + pub npx_flags: u_int32_t, + pub npx_mask: u_int32_t, +} +#[test] +fn bindgen_test_layout_so_np_extensions() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(so_np_extensions)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(so_np_extensions)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).npx_flags) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(so_np_extensions), + "::", + stringify!(npx_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).npx_mask) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(so_np_extensions), + "::", + stringify!(npx_mask) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr { + pub sa_len: __uint8_t, + pub sa_family: sa_family_t, + pub sa_data: [::std::os::raw::c_char; 14usize], +} +#[test] +fn bindgen_test_layout_sockaddr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sockaddr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(sockaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr), "::", stringify!(sa_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_family) as usize - ptr as usize }, + 1usize, + concat!("Offset of field: ", stringify!(sockaddr), "::", stringify!(sa_family)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_data) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(sockaddr), "::", stringify!(sa_data)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockproto { + pub sp_family: __uint16_t, + pub sp_protocol: __uint16_t, +} +#[test] +fn bindgen_test_layout_sockproto() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(sockproto)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(sockproto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sp_family) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockproto), "::", stringify!(sp_family)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sp_protocol) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockproto), + "::", + stringify!(sp_protocol) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_storage { + pub ss_len: __uint8_t, + pub ss_family: sa_family_t, + pub __ss_pad1: [::std::os::raw::c_char; 6usize], + pub __ss_align: __int64_t, + pub __ss_pad2: [::std::os::raw::c_char; 112usize], +} +#[test] +fn bindgen_test_layout_sockaddr_storage() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(sockaddr_storage)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sockaddr_storage)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(ss_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(ss_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss_pad1) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(__ss_pad1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss_align) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(__ss_align) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss_pad2) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(__ss_pad2) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct msghdr { + pub msg_name: *mut ::std::os::raw::c_void, + pub msg_namelen: socklen_t, + pub msg_iov: *mut iovec, + pub msg_iovlen: ::std::os::raw::c_int, + pub msg_control: *mut ::std::os::raw::c_void, + pub msg_controllen: socklen_t, + pub msg_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_namelen) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_namelen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iov) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_iov)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iovlen) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_iovlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_control) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_control)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_controllen) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(msghdr), + "::", + stringify!(msg_controllen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_flags) as usize - ptr as usize }, + 44usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct msghdr_x { + pub msg_name: *mut ::std::os::raw::c_void, + pub msg_namelen: socklen_t, + pub msg_iov: *mut iovec, + pub msg_iovlen: ::std::os::raw::c_int, + pub msg_control: *mut ::std::os::raw::c_void, + pub msg_controllen: socklen_t, + pub msg_flags: ::std::os::raw::c_int, + pub msg_datalen: usize, +} +#[test] +fn bindgen_test_layout_msghdr_x() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(msghdr_x)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(msghdr_x)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(msghdr_x), "::", stringify!(msg_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_namelen) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(msghdr_x), "::", stringify!(msg_namelen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iov) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(msghdr_x), "::", stringify!(msg_iov)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iovlen) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(msghdr_x), "::", stringify!(msg_iovlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_control) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(msghdr_x), "::", stringify!(msg_control)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_controllen) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(msghdr_x), + "::", + stringify!(msg_controllen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_flags) as usize - ptr as usize }, + 44usize, + concat!("Offset of field: ", stringify!(msghdr_x), "::", stringify!(msg_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_datalen) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(msghdr_x), "::", stringify!(msg_datalen)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct cmsghdr { + pub cmsg_len: socklen_t, + pub cmsg_level: ::std::os::raw::c_int, + pub cmsg_type: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_cmsghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(cmsghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(cmsghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmsg_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(cmsghdr), "::", stringify!(cmsg_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmsg_level) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(cmsghdr), "::", stringify!(cmsg_level)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmsg_type) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(cmsghdr), "::", stringify!(cmsg_type)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sf_hdtr { + pub headers: *mut iovec, + pub hdr_cnt: ::std::os::raw::c_int, + pub trailers: *mut iovec, + pub trl_cnt: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_sf_hdtr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(sf_hdtr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sf_hdtr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).headers) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sf_hdtr), "::", stringify!(headers)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hdr_cnt) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sf_hdtr), "::", stringify!(hdr_cnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).trailers) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(sf_hdtr), "::", stringify!(trailers)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).trl_cnt) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(sf_hdtr), "::", stringify!(trl_cnt)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct so_aidreq { + pub sar_cnt: __uint32_t, + pub sar_aidp: *mut sae_associd_t, +} +#[test] +fn bindgen_test_layout_so_aidreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(so_aidreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(so_aidreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sar_cnt) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(so_aidreq), "::", stringify!(sar_cnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sar_aidp) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(so_aidreq), "::", stringify!(sar_aidp)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct so_cidreq { + pub scr_aid: sae_associd_t, + pub scr_cnt: __uint32_t, + pub scr_cidp: *mut sae_connid_t, +} +#[test] +fn bindgen_test_layout_so_cidreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(so_cidreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(so_cidreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scr_aid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(so_cidreq), "::", stringify!(scr_aid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scr_cnt) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(so_cidreq), "::", stringify!(scr_cnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scr_cidp) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(so_cidreq), "::", stringify!(scr_cidp)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct so_cinforeq { + pub scir_cid: sae_connid_t, + pub scir_flags: __uint32_t, + pub scir_ifindex: __uint32_t, + pub scir_error: __int32_t, + pub scir_src: *mut sockaddr, + pub scir_src_len: socklen_t, + pub scir_dst: *mut sockaddr, + pub scir_dst_len: socklen_t, + pub scir_aux_type: __uint32_t, + pub scir_aux_data: *mut ::std::os::raw::c_void, + pub scir_aux_len: __uint32_t, +} +#[test] +fn bindgen_test_layout_so_cinforeq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(so_cinforeq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(so_cinforeq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_cid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(so_cinforeq), "::", stringify!(scir_cid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_flags) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(so_cinforeq), + "::", + stringify!(scir_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_ifindex) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(so_cinforeq), + "::", + stringify!(scir_ifindex) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_error) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(so_cinforeq), + "::", + stringify!(scir_error) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_src) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(so_cinforeq), "::", stringify!(scir_src)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_src_len) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(so_cinforeq), + "::", + stringify!(scir_src_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_dst) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(so_cinforeq), "::", stringify!(scir_dst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_dst_len) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(so_cinforeq), + "::", + stringify!(scir_dst_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_aux_type) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(so_cinforeq), + "::", + stringify!(scir_aux_type) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_aux_data) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(so_cinforeq), + "::", + stringify!(scir_aux_data) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scir_aux_len) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(so_cinforeq), + "::", + stringify!(scir_aux_len) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct so_cordreq { + pub sco_cid: sae_connid_t, + pub sco_rank: __uint32_t, +} +#[test] +fn bindgen_test_layout_so_cordreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(so_cordreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(so_cordreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sco_cid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(so_cordreq), "::", stringify!(sco_cid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sco_rank) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(so_cordreq), "::", stringify!(sco_rank)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct netpolicy_event_data { + pub eupid: __uint64_t, + pub epid: __uint64_t, + pub euuid: uuid_t, +} +#[test] +fn bindgen_test_layout_netpolicy_event_data() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(netpolicy_event_data)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(netpolicy_event_data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).eupid) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(netpolicy_event_data), + "::", + stringify!(eupid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).epid) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(netpolicy_event_data), + "::", + stringify!(epid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).euuid) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(netpolicy_event_data), + "::", + stringify!(euuid) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct kev_netpolicy_ifdenied { + pub ev_data: netpolicy_event_data, + pub ev_if_functional_type: __uint32_t, +} +#[test] +fn bindgen_test_layout_kev_netpolicy_ifdenied() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(kev_netpolicy_ifdenied)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(kev_netpolicy_ifdenied)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ev_data) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(kev_netpolicy_ifdenied), + "::", + stringify!(ev_data) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ev_if_functional_type) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(kev_netpolicy_ifdenied), + "::", + stringify!(ev_if_functional_type) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct kev_netpolicy_netdenied { + pub ev_data: netpolicy_event_data, + pub ev_network_type: __uint32_t, +} +#[test] +fn bindgen_test_layout_kev_netpolicy_netdenied() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(kev_netpolicy_netdenied)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(kev_netpolicy_netdenied)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ev_data) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(kev_netpolicy_netdenied), + "::", + stringify!(ev_data) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ev_network_type) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(kev_netpolicy_netdenied), + "::", + stringify!(ev_network_type) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct netsvctype_dscp_map { + pub netsvctype: ::std::os::raw::c_int, + pub dscp: u_int8_t, +} +#[test] +fn bindgen_test_layout_netsvctype_dscp_map() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(netsvctype_dscp_map)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(netsvctype_dscp_map)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).netsvctype) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(netsvctype_dscp_map), + "::", + stringify!(netsvctype) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dscp) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(netsvctype_dscp_map), + "::", + stringify!(dscp) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct so_mpkl_send_info { + pub mpkl_uuid: uuid_t, + pub mpkl_proto: __uint8_t, +} +#[test] +fn bindgen_test_layout_so_mpkl_send_info() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 17usize, + concat!("Size of: ", stringify!(so_mpkl_send_info)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(so_mpkl_send_info)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mpkl_uuid) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(so_mpkl_send_info), + "::", + stringify!(mpkl_uuid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mpkl_proto) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(so_mpkl_send_info), + "::", + stringify!(mpkl_proto) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct so_mpkl_recv_info { + pub mpkl_seq: __uint32_t, + pub mpkl_proto: __uint8_t, +} +#[test] +fn bindgen_test_layout_so_mpkl_recv_info() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(so_mpkl_recv_info)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(so_mpkl_recv_info)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mpkl_seq) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(so_mpkl_recv_info), + "::", + stringify!(mpkl_seq) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mpkl_proto) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(so_mpkl_recv_info), + "::", + stringify!(mpkl_proto) + ) + ); +} +extern "C" { + pub fn peeloff(s: ::std::os::raw::c_int, arg1: sae_associd_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn socket_delegate( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: pid_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn recvmsg_x( + s: ::std::os::raw::c_int, + msgp: *const msghdr_x, + cnt: u_int, + flags: ::std::os::raw::c_int, + ) -> isize; +} +extern "C" { + pub fn sendmsg_x( + s: ::std::os::raw::c_int, + msgp: *const msghdr_x, + cnt: u_int, + flags: ::std::os::raw::c_int, + ) -> isize; +} +extern "C" { + #[link_name = "\u{1}_accept$UNIX2003"] + pub fn accept(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr, arg3: *mut socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + #[link_name = "\u{1}_bind$UNIX2003"] + pub fn bind(arg1: ::std::os::raw::c_int, arg2: *const sockaddr, arg3: socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + #[link_name = "\u{1}_connect$UNIX2003"] + pub fn connect(arg1: ::std::os::raw::c_int, arg2: *const sockaddr, arg3: socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + #[link_name = "\u{1}_getpeername$UNIX2003"] + pub fn getpeername(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr, arg3: *mut socklen_t) + -> ::std::os::raw::c_int; +} +extern "C" { + #[link_name = "\u{1}_getsockname$UNIX2003"] + pub fn getsockname(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr, arg3: *mut socklen_t) + -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsockopt( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *mut ::std::os::raw::c_void, + arg5: *mut socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + #[link_name = "\u{1}_listen$UNIX2003"] + pub fn listen(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + #[link_name = "\u{1}_recv$UNIX2003"] + pub fn recv( + arg1: ::std::os::raw::c_int, + arg2: *mut ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + ) -> isize; +} +extern "C" { + #[link_name = "\u{1}_recvfrom$UNIX2003"] + pub fn recvfrom( + arg1: ::std::os::raw::c_int, + arg2: *mut ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + arg5: *mut sockaddr, + arg6: *mut socklen_t, + ) -> isize; +} +extern "C" { + #[link_name = "\u{1}_recvmsg$UNIX2003"] + pub fn recvmsg(arg1: ::std::os::raw::c_int, arg2: *mut msghdr, arg3: ::std::os::raw::c_int) -> isize; +} +extern "C" { + #[link_name = "\u{1}_send$UNIX2003"] + pub fn send( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + ) -> isize; +} +extern "C" { + #[link_name = "\u{1}_sendmsg$UNIX2003"] + pub fn sendmsg(arg1: ::std::os::raw::c_int, arg2: *const msghdr, arg3: ::std::os::raw::c_int) -> isize; +} +extern "C" { + #[link_name = "\u{1}_sendto$UNIX2003"] + pub fn sendto( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + arg5: *const sockaddr, + arg6: socklen_t, + ) -> isize; +} +extern "C" { + pub fn setsockopt( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *const ::std::os::raw::c_void, + arg5: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn shutdown(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn sockatmark(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn socket( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + #[link_name = "\u{1}_socketpair$UNIX2003"] + pub fn socketpair( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *mut ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn sendfile( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: off_t, + arg4: *mut off_t, + arg5: *mut sf_hdtr, + arg6: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pfctlinput(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr); +} +extern "C" { + pub fn connectx( + arg1: ::std::os::raw::c_int, + arg2: *const sa_endpoints_t, + arg3: sae_associd_t, + arg4: ::std::os::raw::c_uint, + arg5: *const iovec, + arg6: ::std::os::raw::c_uint, + arg7: *mut usize, + arg8: *mut sae_connid_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn disconnectx(arg1: ::std::os::raw::c_int, arg2: sae_associd_t, arg3: sae_connid_t) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct in_addr { + pub s_addr: in_addr_t, +} +#[test] +fn bindgen_test_layout_in_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(in_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).s_addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(in_addr), "::", stringify!(s_addr)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_in { + pub sin_len: __uint8_t, + pub sin_family: sa_family_t, + pub sin_port: in_port_t, + pub sin_addr: in_addr, + pub sin_zero: [::std::os::raw::c_char; 8usize], +} +#[test] +fn bindgen_test_layout_sockaddr_in() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sockaddr_in)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_in)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in), + "::", + stringify!(sin_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_port) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_addr) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_zero) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_zero)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct sockaddr_inifscope { + pub sin_len: __uint8_t, + pub sin_family: sa_family_t, + pub sin_port: in_port_t, + pub sin_addr: in_addr, + pub un: sockaddr_inifscope__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union sockaddr_inifscope__bindgen_ty_1 { + pub sin_zero: [::std::os::raw::c_char; 8usize], + pub _in_index: sockaddr_inifscope__bindgen_ty_1__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_inifscope__bindgen_ty_1__bindgen_ty_1 { + pub ifscope: __uint32_t, +} +#[test] +fn bindgen_test_layout_sockaddr_inifscope__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = + ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(sockaddr_inifscope__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!( + "Alignment of ", + stringify!(sockaddr_inifscope__bindgen_ty_1__bindgen_ty_1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifscope) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_inifscope__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ifscope) + ) + ); +} +#[test] +fn bindgen_test_layout_sockaddr_inifscope__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(sockaddr_inifscope__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_inifscope__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_zero) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_inifscope__bindgen_ty_1), + "::", + stringify!(sin_zero) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._in_index) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_inifscope__bindgen_ty_1), + "::", + stringify!(_in_index) + ) + ); +} +#[test] +fn bindgen_test_layout_sockaddr_inifscope() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sockaddr_inifscope)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_inifscope)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_inifscope), + "::", + stringify!(sin_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_inifscope), + "::", + stringify!(sin_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_port) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_inifscope), + "::", + stringify!(sin_port) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_addr) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_inifscope), + "::", + stringify!(sin_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).un) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_inifscope), + "::", + stringify!(un) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_opts { + pub ip_dst: in_addr, + pub ip_opts: [::std::os::raw::c_char; 40usize], +} +#[test] +fn bindgen_test_layout_ip_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 44usize, + concat!("Size of: ", stringify!(ip_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip_dst) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ip_opts), "::", stringify!(ip_dst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip_opts) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(ip_opts), "::", stringify!(ip_opts)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_mreq { + pub imr_multiaddr: in_addr, + pub imr_interface: in_addr, +} +#[test] +fn bindgen_test_layout_ip_mreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(ip_mreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_mreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq), + "::", + stringify!(imr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_interface) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq), + "::", + stringify!(imr_interface) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_mreqn { + pub imr_multiaddr: in_addr, + pub imr_address: in_addr, + pub imr_ifindex: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ip_mreqn() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(ip_mreqn)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_mreqn)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip_mreqn), + "::", + stringify!(imr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_address) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(ip_mreqn), "::", stringify!(imr_address)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_ifindex) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(ip_mreqn), "::", stringify!(imr_ifindex)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_mreq_source { + pub imr_multiaddr: in_addr, + pub imr_sourceaddr: in_addr, + pub imr_interface: in_addr, +} +#[test] +fn bindgen_test_layout_ip_mreq_source() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(ip_mreq_source)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_mreq_source)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq_source), + "::", + stringify!(imr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_sourceaddr) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq_source), + "::", + stringify!(imr_sourceaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_interface) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq_source), + "::", + stringify!(imr_interface) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct group_req { + pub gr_interface: u32, + pub gr_group: sockaddr_storage, +} +#[test] +fn bindgen_test_layout_group_req() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 132usize, + concat!("Size of: ", stringify!(group_req)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(group_req)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gr_interface) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(group_req), + "::", + stringify!(gr_interface) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gr_group) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(group_req), "::", stringify!(gr_group)) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct group_source_req { + pub gsr_interface: u32, + pub gsr_group: sockaddr_storage, + pub gsr_source: sockaddr_storage, +} +#[test] +fn bindgen_test_layout_group_source_req() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 260usize, + concat!("Size of: ", stringify!(group_source_req)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(group_source_req)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gsr_interface) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(group_source_req), + "::", + stringify!(gsr_interface) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gsr_group) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(group_source_req), + "::", + stringify!(gsr_group) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gsr_source) as usize - ptr as usize }, + 132usize, + concat!( + "Offset of field: ", + stringify!(group_source_req), + "::", + stringify!(gsr_source) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct __msfilterreq { + pub msfr_ifindex: u32, + pub msfr_fmode: u32, + pub msfr_nsrcs: u32, + pub __msfr_align: u32, + pub msfr_group: sockaddr_storage, + pub msfr_srcs: *mut sockaddr_storage, +} +#[test] +fn bindgen_test_layout___msfilterreq() { + const UNINIT: ::std::mem::MaybeUninit<__msfilterreq> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__msfilterreq>(), + 152usize, + concat!("Size of: ", stringify!(__msfilterreq)) + ); + assert_eq!( + ::std::mem::align_of::<__msfilterreq>(), + 4usize, + concat!("Alignment of ", stringify!(__msfilterreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_ifindex) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_ifindex) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_fmode) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_fmode) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_nsrcs) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_nsrcs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__msfr_align) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(__msfr_align) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_group) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_group) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msfr_srcs) as usize - ptr as usize }, + 144usize, + concat!( + "Offset of field: ", + stringify!(__msfilterreq), + "::", + stringify!(msfr_srcs) + ) + ); +} +extern "C" { + pub fn setipv4sourcefilter( + arg1: ::std::os::raw::c_int, + arg2: in_addr, + arg3: in_addr, + arg4: u32, + arg5: u32, + arg6: *mut in_addr, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getipv4sourcefilter( + arg1: ::std::os::raw::c_int, + arg2: in_addr, + arg3: in_addr, + arg4: *mut u32, + arg5: *mut u32, + arg6: *mut in_addr, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setsourcefilter( + arg1: ::std::os::raw::c_int, + arg2: u32, + arg3: *mut sockaddr, + arg4: socklen_t, + arg5: u32, + arg6: u32, + arg7: *mut sockaddr_storage, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsourcefilter( + arg1: ::std::os::raw::c_int, + arg2: u32, + arg3: *mut sockaddr, + arg4: socklen_t, + arg5: *mut u32, + arg6: *mut u32, + arg7: *mut sockaddr_storage, + ) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct in_pktinfo { + pub ipi_ifindex: ::std::os::raw::c_uint, + pub ipi_spec_dst: in_addr, + pub ipi_addr: in_addr, +} +#[test] +fn bindgen_test_layout_in_pktinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(in_pktinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in_pktinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipi_ifindex) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in_pktinfo), + "::", + stringify!(ipi_ifindex) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipi_spec_dst) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(in_pktinfo), + "::", + stringify!(ipi_spec_dst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipi_addr) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(in_pktinfo), "::", stringify!(ipi_addr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct in6_addr { + pub __u6_addr: in6_addr__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union in6_addr__bindgen_ty_1 { + pub __u6_addr8: [__uint8_t; 16usize], + pub __u6_addr16: [__uint16_t; 8usize], + pub __u6_addr32: [__uint32_t; 4usize], +} +#[test] +fn bindgen_test_layout_in6_addr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(in6_addr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in6_addr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_addr__bindgen_ty_1), + "::", + stringify!(__u6_addr8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr16) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_addr__bindgen_ty_1), + "::", + stringify!(__u6_addr16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr32) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_addr__bindgen_ty_1), + "::", + stringify!(__u6_addr32) + ) + ); +} +#[test] +fn bindgen_test_layout_in6_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(in6_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in6_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(in6_addr), "::", stringify!(__u6_addr)) + ); +} +pub type in6_addr_t = in6_addr; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct sockaddr_in6 { + pub sin6_len: __uint8_t, + pub sin6_family: sa_family_t, + pub sin6_port: in_port_t, + pub sin6_flowinfo: __uint32_t, + pub sin6_addr: in6_addr, + pub sin6_scope_id: __uint32_t, +} +#[test] +fn bindgen_test_layout_sockaddr_in6() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 28usize, + concat!("Size of: ", stringify!(sockaddr_in6)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_in6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_port) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_port) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_flowinfo) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_flowinfo) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_addr) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_scope_id) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_scope_id) + ) + ); +} +extern "C" { + pub static in6addr_any: in6_addr; +} +extern "C" { + pub static in6addr_loopback: in6_addr; +} +extern "C" { + pub static in6addr_nodelocal_allnodes: in6_addr; +} +extern "C" { + pub static in6addr_linklocal_allnodes: in6_addr; +} +extern "C" { + pub static in6addr_linklocal_allrouters: in6_addr; +} +extern "C" { + pub static in6addr_linklocal_allv2routers: in6_addr; +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct route_in6_old { + pub ro_rt: *mut ::std::os::raw::c_void, + pub ro_flags: u32, + pub ro_dst: sockaddr_in6, +} +#[test] +fn bindgen_test_layout_route_in6_old() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(route_in6_old)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(route_in6_old)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_rt) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(route_in6_old), "::", stringify!(ro_rt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_flags) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(route_in6_old), + "::", + stringify!(ro_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_dst) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(route_in6_old), "::", stringify!(ro_dst)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ipv6_mreq { + pub ipv6mr_multiaddr: in6_addr, + pub ipv6mr_interface: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_ipv6_mreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(ipv6_mreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ipv6_mreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipv6mr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ipv6_mreq), + "::", + stringify!(ipv6mr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipv6mr_interface) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ipv6_mreq), + "::", + stringify!(ipv6mr_interface) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct in6_pktinfo { + pub ipi6_addr: in6_addr, + pub ipi6_ifindex: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_in6_pktinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(in6_pktinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in6_pktinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipi6_addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_pktinfo), + "::", + stringify!(ipi6_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipi6_ifindex) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(in6_pktinfo), + "::", + stringify!(ipi6_ifindex) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ip6_mtuinfo { + pub ip6m_addr: sockaddr_in6, + pub ip6m_mtu: u32, +} +#[test] +fn bindgen_test_layout_ip6_mtuinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(ip6_mtuinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip6_mtuinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip6m_addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip6_mtuinfo), + "::", + stringify!(ip6m_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip6m_mtu) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(ip6_mtuinfo), "::", stringify!(ip6m_mtu)) + ); +} +pub const in6_clat46_evhdlr_code_t_IN6_CLAT46_EVENT_V4_FLOW: in6_clat46_evhdlr_code_t = 0; +pub const in6_clat46_evhdlr_code_t_IN6_CLAT46_EVENT_V6_ADDR_CONFFAIL: in6_clat46_evhdlr_code_t = 1; +pub type in6_clat46_evhdlr_code_t = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct kev_netevent_clat46_data { + pub clat46_event_code: in6_clat46_evhdlr_code_t, + pub epid: pid_t, + pub euuid: uuid_t, +} +#[test] +fn bindgen_test_layout_kev_netevent_clat46_data() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(kev_netevent_clat46_data)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(kev_netevent_clat46_data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).clat46_event_code) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(kev_netevent_clat46_data), + "::", + stringify!(clat46_event_code) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).epid) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(kev_netevent_clat46_data), + "::", + stringify!(epid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).euuid) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(kev_netevent_clat46_data), + "::", + stringify!(euuid) + ) + ); +} +extern "C" { + pub fn inet6_option_space(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_option_init( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut *mut cmsghdr, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_option_append( + arg1: *mut cmsghdr, + arg2: *const __uint8_t, + arg3: ::std::os::raw::c_int, + arg4: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_option_alloc( + arg1: *mut cmsghdr, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: ::std::os::raw::c_int, + ) -> *mut __uint8_t; +} +extern "C" { + pub fn inet6_option_next(arg1: *const cmsghdr, arg2: *mut *mut __uint8_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_option_find( + arg1: *const cmsghdr, + arg2: *mut *mut __uint8_t, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rthdr_space(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> usize; +} +extern "C" { + pub fn inet6_rthdr_init(arg1: *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_int) -> *mut cmsghdr; +} +extern "C" { + pub fn inet6_rthdr_add( + arg1: *mut cmsghdr, + arg2: *const in6_addr, + arg3: ::std::os::raw::c_uint, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rthdr_lasthop(arg1: *mut cmsghdr, arg2: ::std::os::raw::c_uint) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rthdr_segments(arg1: *const cmsghdr) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rthdr_getaddr(arg1: *mut cmsghdr, arg2: ::std::os::raw::c_int) -> *mut in6_addr; +} +extern "C" { + pub fn inet6_rthdr_getflags(arg1: *const cmsghdr, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_init(arg1: *mut ::std::os::raw::c_void, arg2: socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_append( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: __uint8_t, + arg5: socklen_t, + arg6: __uint8_t, + arg7: *mut *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_finish( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_set_val( + arg1: *mut ::std::os::raw::c_void, + arg2: ::std::os::raw::c_int, + arg3: *mut ::std::os::raw::c_void, + arg4: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_next( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: *mut __uint8_t, + arg5: *mut socklen_t, + arg6: *mut *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_find( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: __uint8_t, + arg5: *mut socklen_t, + arg6: *mut *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_get_val( + arg1: *mut ::std::os::raw::c_void, + arg2: ::std::os::raw::c_int, + arg3: *mut ::std::os::raw::c_void, + arg4: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_space(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> socklen_t; +} +extern "C" { + pub fn inet6_rth_init( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn inet6_rth_add(arg1: *mut ::std::os::raw::c_void, arg2: *const in6_addr) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_reverse( + arg1: *const ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_segments(arg1: *const ::std::os::raw::c_void) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_getaddr(arg1: *const ::std::os::raw::c_void, arg2: ::std::os::raw::c_int) -> *mut in6_addr; +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union sockaddr_in_4_6 { + pub sa: sockaddr, + pub sin: sockaddr_in, + pub sin6: sockaddr_in6, +} +#[test] +fn bindgen_test_layout_sockaddr_in_4_6() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 28usize, + concat!("Size of: ", stringify!(sockaddr_in_4_6)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_in_4_6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_in_4_6), "::", stringify!(sa)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_in_4_6), "::", stringify!(sin)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_in_4_6), "::", stringify!(sin6)) + ); +} +extern "C" { + pub fn bindresvport(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr_in) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn bindresvport_sa(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timespec { + pub tv_sec: __darwin_time_t, + pub tv_nsec: ::std::os::raw::c_long, +} +#[test] +fn bindgen_test_layout_timespec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timespec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(timespec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(timespec), "::", stringify!(tv_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_nsec) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(timespec), "::", stringify!(tv_nsec)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timeval { + pub tv_sec: __darwin_time_t, + pub tv_usec: __darwin_suseconds_t, +} +#[test] +fn bindgen_test_layout_timeval() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timeval)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(timeval)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(timeval), "::", stringify!(tv_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_usec) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(timeval), "::", stringify!(tv_usec)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timeval64 { + pub tv_sec: __int64_t, + pub tv_usec: __int64_t, +} +#[test] +fn bindgen_test_layout_timeval64() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timeval64)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(timeval64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(timeval64), "::", stringify!(tv_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_usec) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(timeval64), "::", stringify!(tv_usec)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct itimerval { + pub it_interval: timeval, + pub it_value: timeval, +} +#[test] +fn bindgen_test_layout_itimerval() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(itimerval)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(itimerval)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_interval) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(itimerval), + "::", + stringify!(it_interval) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_value) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(itimerval), "::", stringify!(it_value)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timezone { + pub tz_minuteswest: ::std::os::raw::c_int, + pub tz_dsttime: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_timezone() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(timezone)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(timezone)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tz_minuteswest) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timezone), + "::", + stringify!(tz_minuteswest) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tz_dsttime) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(timezone), "::", stringify!(tz_dsttime)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct clockinfo { + pub hz: ::std::os::raw::c_int, + pub tick: ::std::os::raw::c_int, + pub tickadj: ::std::os::raw::c_int, + pub stathz: ::std::os::raw::c_int, + pub profhz: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_clockinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(clockinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(clockinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hz) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(hz)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tick) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(tick)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tickadj) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(tickadj)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).stathz) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(stathz)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).profhz) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(profhz)) + ); +} +pub type __darwin_nl_item = ::std::os::raw::c_int; +pub type __darwin_wctrans_t = ::std::os::raw::c_int; +pub type __darwin_wctype_t = __uint32_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct tm { + pub tm_sec: ::std::os::raw::c_int, + pub tm_min: ::std::os::raw::c_int, + pub tm_hour: ::std::os::raw::c_int, + pub tm_mday: ::std::os::raw::c_int, + pub tm_mon: ::std::os::raw::c_int, + pub tm_year: ::std::os::raw::c_int, + pub tm_wday: ::std::os::raw::c_int, + pub tm_yday: ::std::os::raw::c_int, + pub tm_isdst: ::std::os::raw::c_int, + pub tm_gmtoff: ::std::os::raw::c_long, + pub tm_zone: *mut ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_tm() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(tm)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(tm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_min) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_min)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_hour) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_hour)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_mday) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_mday)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_mon) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_mon)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_year) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_year)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_wday) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_wday)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_yday) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_yday)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_isdst) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_isdst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_gmtoff) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_gmtoff)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_zone) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_zone)) + ); +} +extern "C" { + pub static mut tzname: [*mut ::std::os::raw::c_char; 0usize]; +} +extern "C" { + pub static mut getdate_err: ::std::os::raw::c_int; +} +extern "C" { + #[link_name = "\u{1}_timezone$UNIX2003"] + pub static mut timezone: ::std::os::raw::c_long; +} +extern "C" { + pub static mut daylight: ::std::os::raw::c_int; +} +extern "C" { + pub fn asctime(arg1: *const tm) -> *mut ::std::os::raw::c_char; +} +extern "C" { + #[link_name = "\u{1}_clock$UNIX2003"] + pub fn clock() -> clock_t; +} +extern "C" { + pub fn ctime(arg1: *const time_t) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn difftime(arg1: time_t, arg2: time_t) -> f64; +} +extern "C" { + pub fn getdate(arg1: *const ::std::os::raw::c_char) -> *mut tm; +} +extern "C" { + pub fn gmtime(arg1: *const time_t) -> *mut tm; +} +extern "C" { + pub fn localtime(arg1: *const time_t) -> *mut tm; +} +extern "C" { + #[link_name = "\u{1}_mktime$UNIX2003"] + pub fn mktime(arg1: *mut tm) -> time_t; +} +extern "C" { + #[link_name = "\u{1}_strftime$UNIX2003"] + pub fn strftime( + arg1: *mut ::std::os::raw::c_char, + arg2: usize, + arg3: *const ::std::os::raw::c_char, + arg4: *const tm, + ) -> usize; +} +extern "C" { + #[link_name = "\u{1}_strptime$UNIX2003"] + pub fn strptime( + arg1: *const ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + arg3: *mut tm, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn time(arg1: *mut time_t) -> time_t; +} +extern "C" { + pub fn tzset(); +} +extern "C" { + pub fn asctime_r(arg1: *const tm, arg2: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ctime_r(arg1: *const time_t, arg2: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn gmtime_r(arg1: *const time_t, arg2: *mut tm) -> *mut tm; +} +extern "C" { + pub fn localtime_r(arg1: *const time_t, arg2: *mut tm) -> *mut tm; +} +extern "C" { + pub fn posix2time(arg1: time_t) -> time_t; +} +extern "C" { + pub fn tzsetwall(); +} +extern "C" { + pub fn time2posix(arg1: time_t) -> time_t; +} +extern "C" { + pub fn timelocal(arg1: *mut tm) -> time_t; +} +extern "C" { + pub fn timegm(arg1: *mut tm) -> time_t; +} +extern "C" { + #[link_name = "\u{1}_nanosleep$UNIX2003"] + pub fn nanosleep(__rqtp: *const timespec, __rmtp: *mut timespec) -> ::std::os::raw::c_int; +} +pub const clockid_t__CLOCK_REALTIME: clockid_t = 0; +pub const clockid_t__CLOCK_MONOTONIC: clockid_t = 6; +pub const clockid_t__CLOCK_MONOTONIC_RAW: clockid_t = 4; +pub const clockid_t__CLOCK_MONOTONIC_RAW_APPROX: clockid_t = 5; +pub const clockid_t__CLOCK_UPTIME_RAW: clockid_t = 8; +pub const clockid_t__CLOCK_UPTIME_RAW_APPROX: clockid_t = 9; +pub const clockid_t__CLOCK_PROCESS_CPUTIME_ID: clockid_t = 12; +pub const clockid_t__CLOCK_THREAD_CPUTIME_ID: clockid_t = 16; +pub type clockid_t = ::std::os::raw::c_uint; +extern "C" { + pub fn clock_getres(__clock_id: clockid_t, __res: *mut timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_gettime(__clock_id: clockid_t, __tp: *mut timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_gettime_nsec_np(__clock_id: clockid_t) -> __uint64_t; +} +extern "C" { + pub fn clock_settime(__clock_id: clockid_t, __tp: *const timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn timespec_get(ts: *mut timespec, base: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn adjtime(arg1: *const timeval, arg2: *mut timeval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn futimes(arg1: ::std::os::raw::c_int, arg2: *const timeval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn lutimes(arg1: *const ::std::os::raw::c_char, arg2: *const timeval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn settimeofday(arg1: *const timeval, arg2: *const timezone) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getitimer(arg1: ::std::os::raw::c_int, arg2: *mut itimerval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn gettimeofday(arg1: *mut timeval, arg2: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int; +} +extern "C" { + #[link_name = "\u{1}_select$1050"] + pub fn select( + arg1: ::std::os::raw::c_int, + arg2: *mut fd_set, + arg3: *mut fd_set, + arg4: *mut fd_set, + arg5: *mut timeval, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setitimer( + arg1: ::std::os::raw::c_int, + arg2: *const itimerval, + arg3: *mut itimerval, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn utimes(arg1: *const ::std::os::raw::c_char, arg2: *const timeval) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_metrics { + pub rmx_locks: u_int32_t, + pub rmx_mtu: u_int32_t, + pub rmx_hopcount: u_int32_t, + pub rmx_expire: i32, + pub rmx_recvpipe: u_int32_t, + pub rmx_sendpipe: u_int32_t, + pub rmx_ssthresh: u_int32_t, + pub rmx_rtt: u_int32_t, + pub rmx_rttvar: u_int32_t, + pub rmx_pksent: u_int32_t, + pub rmx_state: u_int32_t, + pub rmx_filler: [u_int32_t; 3usize], +} +#[test] +fn bindgen_test_layout_rt_metrics() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(rt_metrics)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(rt_metrics)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_locks) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rt_metrics), "::", stringify!(rmx_locks)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_mtu) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(rt_metrics), "::", stringify!(rmx_mtu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_hopcount) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_hopcount) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_expire) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_expire) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_recvpipe) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_recvpipe) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_sendpipe) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_sendpipe) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_ssthresh) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_ssthresh) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_rtt) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(rt_metrics), "::", stringify!(rmx_rtt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_rttvar) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_rttvar) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_pksent) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_pksent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_state) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(rt_metrics), "::", stringify!(rmx_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_filler) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_filler) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct route_old { + pub ro_rt: *mut ::std::os::raw::c_void, + pub ro_flags: u32, + pub ro_dst: sockaddr, +} +#[test] +fn bindgen_test_layout_route_old() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(route_old)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(route_old)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_rt) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(route_old), "::", stringify!(ro_rt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_flags) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(route_old), "::", stringify!(ro_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_dst) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(route_old), "::", stringify!(ro_dst)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rtstat { + pub rts_badredirect: ::std::os::raw::c_short, + pub rts_dynamic: ::std::os::raw::c_short, + pub rts_newgateway: ::std::os::raw::c_short, + pub rts_unreach: ::std::os::raw::c_short, + pub rts_wildcard: ::std::os::raw::c_short, + pub rts_badrtgwroute: ::std::os::raw::c_short, +} +#[test] +fn bindgen_test_layout_rtstat() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(rtstat)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(rtstat)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_badredirect) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rtstat), + "::", + stringify!(rts_badredirect) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_dynamic) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(rtstat), "::", stringify!(rts_dynamic)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_newgateway) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(rtstat), + "::", + stringify!(rts_newgateway) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_unreach) as usize - ptr as usize }, + 6usize, + concat!("Offset of field: ", stringify!(rtstat), "::", stringify!(rts_unreach)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_wildcard) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(rtstat), "::", stringify!(rts_wildcard)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_badrtgwroute) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(rtstat), + "::", + stringify!(rts_badrtgwroute) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_msghdr { + pub rtm_msglen: u_short, + pub rtm_version: u_char, + pub rtm_type: u_char, + pub rtm_index: u_short, + pub rtm_flags: ::std::os::raw::c_int, + pub rtm_addrs: ::std::os::raw::c_int, + pub rtm_pid: pid_t, + pub rtm_seq: ::std::os::raw::c_int, + pub rtm_errno: ::std::os::raw::c_int, + pub rtm_use: ::std::os::raw::c_int, + pub rtm_inits: u_int32_t, + pub rtm_rmx: rt_metrics, +} +#[test] +fn bindgen_test_layout_rt_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 92usize, + concat!("Size of: ", stringify!(rt_msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(rt_msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_msglen) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_msglen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr), + "::", + stringify!(rtm_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_type) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_index) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_index)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_flags) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_addrs) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_addrs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_pid) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_pid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_seq) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_seq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_errno) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_errno)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_use) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_use)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_inits) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_inits)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_rmx) as usize - ptr as usize }, + 36usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_rmx)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_msghdr2 { + pub rtm_msglen: u_short, + pub rtm_version: u_char, + pub rtm_type: u_char, + pub rtm_index: u_short, + pub rtm_flags: ::std::os::raw::c_int, + pub rtm_addrs: ::std::os::raw::c_int, + pub rtm_refcnt: i32, + pub rtm_parentflags: ::std::os::raw::c_int, + pub rtm_reserved: ::std::os::raw::c_int, + pub rtm_use: ::std::os::raw::c_int, + pub rtm_inits: u_int32_t, + pub rtm_rmx: rt_metrics, +} +#[test] +fn bindgen_test_layout_rt_msghdr2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 92usize, + concat!("Size of: ", stringify!(rt_msghdr2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(rt_msghdr2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr2), + "::", + stringify!(rtm_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr2), + "::", + stringify!(rtm_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_type) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(rt_msghdr2), "::", stringify!(rtm_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_index) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(rt_msghdr2), "::", stringify!(rtm_index)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_flags) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(rt_msghdr2), "::", stringify!(rtm_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_addrs) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(rt_msghdr2), "::", stringify!(rtm_addrs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_refcnt) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr2), + "::", + stringify!(rtm_refcnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_parentflags) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr2), + "::", + stringify!(rtm_parentflags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_reserved) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr2), + "::", + stringify!(rtm_reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_use) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(rt_msghdr2), "::", stringify!(rtm_use)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_inits) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(rt_msghdr2), "::", stringify!(rtm_inits)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_rmx) as usize - ptr as usize }, + 36usize, + concat!("Offset of field: ", stringify!(rt_msghdr2), "::", stringify!(rtm_rmx)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct kev_netevent_apnfallbk_data { + pub epid: pid_t, + pub euuid: uuid_t, +} +#[test] +fn bindgen_test_layout_kev_netevent_apnfallbk_data() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(kev_netevent_apnfallbk_data)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(kev_netevent_apnfallbk_data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).epid) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(kev_netevent_apnfallbk_data), + "::", + stringify!(epid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).euuid) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(kev_netevent_apnfallbk_data), + "::", + stringify!(euuid) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_reach_info { + pub ri_refcnt: u_int32_t, + pub ri_probes: u_int32_t, + pub ri_snd_expire: u_int64_t, + pub ri_rcv_expire: u_int64_t, + pub ri_rssi: i32, + pub ri_lqm: i32, + pub ri_npm: i32, +} +#[test] +fn bindgen_test_layout_rt_reach_info() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(rt_reach_info)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rt_reach_info)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ri_refcnt) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rt_reach_info), + "::", + stringify!(ri_refcnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ri_probes) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(rt_reach_info), + "::", + stringify!(ri_probes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ri_snd_expire) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(rt_reach_info), + "::", + stringify!(ri_snd_expire) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ri_rcv_expire) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(rt_reach_info), + "::", + stringify!(ri_rcv_expire) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ri_rssi) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(rt_reach_info), + "::", + stringify!(ri_rssi) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ri_lqm) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(rt_reach_info), "::", stringify!(ri_lqm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ri_npm) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(rt_reach_info), "::", stringify!(ri_npm)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_msghdr_ext { + pub rtm_msglen: u_short, + pub rtm_version: u_char, + pub rtm_type: u_char, + pub rtm_index: u_int32_t, + pub rtm_flags: u_int32_t, + pub rtm_reserved: u_int32_t, + pub rtm_addrs: u_int32_t, + pub rtm_pid: pid_t, + pub rtm_seq: ::std::os::raw::c_int, + pub rtm_errno: ::std::os::raw::c_int, + pub rtm_use: u_int32_t, + pub rtm_inits: u_int32_t, + pub rtm_rmx: rt_metrics, + pub rtm_ri: rt_reach_info, +} +#[test] +fn bindgen_test_layout_rt_msghdr_ext() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 136usize, + concat!("Size of: ", stringify!(rt_msghdr_ext)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rt_msghdr_ext)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_type) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_type) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_index) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_flags) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_reserved) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_addrs) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_addrs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_pid) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_pid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_seq) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_seq) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_errno) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_errno) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_use) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_use) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_inits) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_inits) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_rmx) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr_ext), + "::", + stringify!(rtm_rmx) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_ri) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(rt_msghdr_ext), "::", stringify!(rtm_ri)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_addrinfo { + pub rti_addrs: ::std::os::raw::c_int, + pub rti_info: [*mut sockaddr; 8usize], +} +#[test] +fn bindgen_test_layout_rt_addrinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 72usize, + concat!("Size of: ", stringify!(rt_addrinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rt_addrinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_addrs) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rt_addrinfo), + "::", + stringify!(rti_addrs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_info) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(rt_addrinfo), "::", stringify!(rti_info)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct net_event_data { + pub if_family: u_int32_t, + pub if_unit: u_int32_t, + pub if_name: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_net_event_data() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(net_event_data)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(net_event_data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_family) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(net_event_data), + "::", + stringify!(if_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_unit) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(net_event_data), + "::", + stringify!(if_unit) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_name) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(net_event_data), + "::", + stringify!(if_name) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timeval32 { + pub tv_sec: __int32_t, + pub tv_usec: __int32_t, +} +#[test] +fn bindgen_test_layout_timeval32() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(timeval32)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(timeval32)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(timeval32), "::", stringify!(tv_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_usec) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(timeval32), "::", stringify!(tv_usec)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_data { + pub ifi_type: u_char, + pub ifi_typelen: u_char, + pub ifi_physical: u_char, + pub ifi_addrlen: u_char, + pub ifi_hdrlen: u_char, + pub ifi_recvquota: u_char, + pub ifi_xmitquota: u_char, + pub ifi_unused1: u_char, + pub ifi_mtu: u_int32_t, + pub ifi_metric: u_int32_t, + pub ifi_baudrate: u_int32_t, + pub ifi_ipackets: u_int32_t, + pub ifi_ierrors: u_int32_t, + pub ifi_opackets: u_int32_t, + pub ifi_oerrors: u_int32_t, + pub ifi_collisions: u_int32_t, + pub ifi_ibytes: u_int32_t, + pub ifi_obytes: u_int32_t, + pub ifi_imcasts: u_int32_t, + pub ifi_omcasts: u_int32_t, + pub ifi_iqdrops: u_int32_t, + pub ifi_noproto: u_int32_t, + pub ifi_recvtiming: u_int32_t, + pub ifi_xmittiming: u_int32_t, + pub ifi_lastchange: timeval32, + pub ifi_unused2: u_int32_t, + pub ifi_hwassist: u_int32_t, + pub ifi_reserved1: u_int32_t, + pub ifi_reserved2: u_int32_t, +} +#[test] +fn bindgen_test_layout_if_data() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(if_data)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_type) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_typelen) as usize - ptr as usize }, + 1usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_typelen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_physical) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_physical)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_addrlen) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_addrlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_hdrlen) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_hdrlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_recvquota) as usize - ptr as usize }, + 5usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_recvquota) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_xmitquota) as usize - ptr as usize }, + 6usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_xmitquota) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_unused1) as usize - ptr as usize }, + 7usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_unused1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_mtu) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_mtu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_metric) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_metric)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_baudrate) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_baudrate)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ipackets) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_ipackets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ierrors) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_ierrors)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_opackets) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_opackets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_oerrors) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_oerrors)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_collisions) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_collisions) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ibytes) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_ibytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_obytes) as usize - ptr as usize }, + 44usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_obytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_imcasts) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_imcasts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_omcasts) as usize - ptr as usize }, + 52usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_omcasts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_iqdrops) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_iqdrops)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_noproto) as usize - ptr as usize }, + 60usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_noproto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_recvtiming) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_recvtiming) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_xmittiming) as usize - ptr as usize }, + 68usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_xmittiming) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_lastchange) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_lastchange) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_unused2) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_unused2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_hwassist) as usize - ptr as usize }, + 84usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_hwassist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_reserved1) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_reserved1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_reserved2) as usize - ptr as usize }, + 92usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_reserved2) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_data64 { + pub ifi_type: u_char, + pub ifi_typelen: u_char, + pub ifi_physical: u_char, + pub ifi_addrlen: u_char, + pub ifi_hdrlen: u_char, + pub ifi_recvquota: u_char, + pub ifi_xmitquota: u_char, + pub ifi_unused1: u_char, + pub ifi_mtu: u_int32_t, + pub ifi_metric: u_int32_t, + pub ifi_baudrate: u_int64_t, + pub ifi_ipackets: u_int64_t, + pub ifi_ierrors: u_int64_t, + pub ifi_opackets: u_int64_t, + pub ifi_oerrors: u_int64_t, + pub ifi_collisions: u_int64_t, + pub ifi_ibytes: u_int64_t, + pub ifi_obytes: u_int64_t, + pub ifi_imcasts: u_int64_t, + pub ifi_omcasts: u_int64_t, + pub ifi_iqdrops: u_int64_t, + pub ifi_noproto: u_int64_t, + pub ifi_recvtiming: u_int32_t, + pub ifi_xmittiming: u_int32_t, + pub ifi_lastchange: timeval32, +} +#[test] +fn bindgen_test_layout_if_data64() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(if_data64)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_data64)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_type) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_data64), "::", stringify!(ifi_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_typelen) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_typelen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_physical) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_physical) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_addrlen) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_addrlen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_hdrlen) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(if_data64), "::", stringify!(ifi_hdrlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_recvquota) as usize - ptr as usize }, + 5usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_recvquota) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_xmitquota) as usize - ptr as usize }, + 6usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_xmitquota) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_unused1) as usize - ptr as usize }, + 7usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_unused1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_mtu) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_data64), "::", stringify!(ifi_mtu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_metric) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(if_data64), "::", stringify!(ifi_metric)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_baudrate) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_baudrate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ipackets) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_ipackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ierrors) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_ierrors) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_opackets) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_opackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_oerrors) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_oerrors) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_collisions) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_collisions) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ibytes) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(if_data64), "::", stringify!(ifi_ibytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_obytes) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(if_data64), "::", stringify!(ifi_obytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_imcasts) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_imcasts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_omcasts) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_omcasts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_iqdrops) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_iqdrops) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_noproto) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_noproto) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_recvtiming) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_recvtiming) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_xmittiming) as usize - ptr as usize }, + 116usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_xmittiming) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_lastchange) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(if_data64), + "::", + stringify!(ifi_lastchange) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_traffic_class { + pub ifi_ibepackets: u_int64_t, + pub ifi_ibebytes: u_int64_t, + pub ifi_obepackets: u_int64_t, + pub ifi_obebytes: u_int64_t, + pub ifi_ibkpackets: u_int64_t, + pub ifi_ibkbytes: u_int64_t, + pub ifi_obkpackets: u_int64_t, + pub ifi_obkbytes: u_int64_t, + pub ifi_ivipackets: u_int64_t, + pub ifi_ivibytes: u_int64_t, + pub ifi_ovipackets: u_int64_t, + pub ifi_ovibytes: u_int64_t, + pub ifi_ivopackets: u_int64_t, + pub ifi_ivobytes: u_int64_t, + pub ifi_ovopackets: u_int64_t, + pub ifi_ovobytes: u_int64_t, + pub ifi_ipvpackets: u_int64_t, + pub ifi_ipvbytes: u_int64_t, + pub ifi_opvpackets: u_int64_t, + pub ifi_opvbytes: u_int64_t, +} +#[test] +fn bindgen_test_layout_if_traffic_class() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 160usize, + concat!("Size of: ", stringify!(if_traffic_class)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_traffic_class)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ibepackets) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ibepackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ibebytes) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ibebytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_obepackets) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_obepackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_obebytes) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_obebytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ibkpackets) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ibkpackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ibkbytes) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ibkbytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_obkpackets) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_obkpackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_obkbytes) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_obkbytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ivipackets) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ivipackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ivibytes) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ivibytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ovipackets) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ovipackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ovibytes) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ovibytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ivopackets) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ivopackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ivobytes) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ivobytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ovopackets) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ovopackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ovobytes) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ovobytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ipvpackets) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ipvpackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ipvbytes) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_ipvbytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_opvpackets) as usize - ptr as usize }, + 144usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_opvpackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_opvbytes) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(if_traffic_class), + "::", + stringify!(ifi_opvbytes) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_data_extended { + pub ifi_alignerrs: u_int64_t, + pub ifi_dt_bytes: u_int64_t, + pub ifi_fpackets: u_int64_t, + pub ifi_fbytes: u_int64_t, + pub reserved: [u_int64_t; 12usize], +} +#[test] +fn bindgen_test_layout_if_data_extended() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(if_data_extended)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_data_extended)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_alignerrs) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_data_extended), + "::", + stringify!(ifi_alignerrs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_dt_bytes) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_data_extended), + "::", + stringify!(ifi_dt_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_fpackets) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_data_extended), + "::", + stringify!(ifi_fpackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_fbytes) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_data_extended), + "::", + stringify!(ifi_fbytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_data_extended), + "::", + stringify!(reserved) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_packet_stats { + pub ifi_tcp_badformat: u_int64_t, + pub ifi_tcp_unspecv6: u_int64_t, + pub ifi_tcp_synfin: u_int64_t, + pub ifi_tcp_badformatipsec: u_int64_t, + pub ifi_tcp_noconnnolist: u_int64_t, + pub ifi_tcp_noconnlist: u_int64_t, + pub ifi_tcp_listbadsyn: u_int64_t, + pub ifi_tcp_icmp6unreach: u_int64_t, + pub ifi_tcp_deprecate6: u_int64_t, + pub ifi_tcp_rstinsynrcv: u_int64_t, + pub ifi_tcp_ooopacket: u_int64_t, + pub ifi_tcp_dospacket: u_int64_t, + pub ifi_tcp_cleanup: u_int64_t, + pub ifi_tcp_synwindow: u_int64_t, + pub reserved: [u_int64_t; 6usize], + pub ifi_udp_port_unreach: u_int64_t, + pub ifi_udp_faithprefix: u_int64_t, + pub ifi_udp_port0: u_int64_t, + pub ifi_udp_badlength: u_int64_t, + pub ifi_udp_badchksum: u_int64_t, + pub ifi_udp_badmcast: u_int64_t, + pub ifi_udp_cleanup: u_int64_t, + pub ifi_udp_badipsec: u_int64_t, + pub _reserved: [u_int64_t; 4usize], +} +#[test] +fn bindgen_test_layout_if_packet_stats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 256usize, + concat!("Size of: ", stringify!(if_packet_stats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_packet_stats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_badformat) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_badformat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_unspecv6) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_unspecv6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_synfin) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_synfin) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_badformatipsec) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_badformatipsec) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_noconnnolist) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_noconnnolist) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_noconnlist) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_noconnlist) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_listbadsyn) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_listbadsyn) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_icmp6unreach) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_icmp6unreach) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_deprecate6) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_deprecate6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_rstinsynrcv) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_rstinsynrcv) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_ooopacket) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_ooopacket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_dospacket) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_dospacket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_cleanup) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_cleanup) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_tcp_synwindow) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_tcp_synwindow) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_udp_port_unreach) as usize - ptr as usize }, + 160usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_udp_port_unreach) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_udp_faithprefix) as usize - ptr as usize }, + 168usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_udp_faithprefix) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_udp_port0) as usize - ptr as usize }, + 176usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_udp_port0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_udp_badlength) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_udp_badlength) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_udp_badchksum) as usize - ptr as usize }, + 192usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_udp_badchksum) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_udp_badmcast) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_udp_badmcast) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_udp_cleanup) as usize - ptr as usize }, + 208usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_udp_cleanup) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_udp_badipsec) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(ifi_udp_badipsec) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._reserved) as usize - ptr as usize }, + 224usize, + concat!( + "Offset of field: ", + stringify!(if_packet_stats), + "::", + stringify!(_reserved) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_description { + pub ifd_maxlen: u_int32_t, + pub ifd_len: u_int32_t, + pub ifd_desc: *mut u_int8_t, +} +#[test] +fn bindgen_test_layout_if_description() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_description)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_description)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifd_maxlen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_description), + "::", + stringify!(ifd_maxlen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifd_len) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_description), + "::", + stringify!(ifd_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifd_desc) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_description), + "::", + stringify!(ifd_desc) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_bandwidths { + pub eff_bw: u64, + pub max_bw: u64, +} +#[test] +fn bindgen_test_layout_if_bandwidths() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_bandwidths)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_bandwidths)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).eff_bw) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_bandwidths), "::", stringify!(eff_bw)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_bw) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_bandwidths), "::", stringify!(max_bw)) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_latencies { + pub eff_lt: u_int64_t, + pub max_lt: u_int64_t, +} +#[test] +fn bindgen_test_layout_if_latencies() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_latencies)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_latencies)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).eff_lt) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_latencies), "::", stringify!(eff_lt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_lt) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_latencies), "::", stringify!(max_lt)) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_netem_params { + pub ifnetem_bandwidth_bps: u64, + pub ifnetem_latency_ms: u32, + pub ifnetem_jitter_ms: u32, + pub ifnetem_corruption_p: u32, + pub ifnetem_duplication_p: u32, + pub ifnetem_loss_p_gr_gl: u32, + pub ifnetem_loss_p_gr_bl: u32, + pub ifnetem_loss_p_bl_br: u32, + pub ifnetem_loss_p_bl_gr: u32, + pub ifnetem_loss_p_br_bl: u32, + pub ifnetem_reordering_p: u32, +} +#[test] +fn bindgen_test_layout_if_netem_params() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(if_netem_params)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_netem_params)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_bandwidth_bps) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_bandwidth_bps) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_latency_ms) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_latency_ms) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_jitter_ms) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_jitter_ms) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_corruption_p) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_corruption_p) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_duplication_p) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_duplication_p) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_loss_p_gr_gl) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_loss_p_gr_gl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_loss_p_gr_bl) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_loss_p_gr_bl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_loss_p_bl_br) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_loss_p_bl_br) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_loss_p_bl_gr) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_loss_p_bl_gr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_loss_p_br_bl) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_loss_p_br_bl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnetem_reordering_p) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(if_netem_params), + "::", + stringify!(ifnetem_reordering_p) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_rxpoll_stats { + pub ifi_poll_off_req: u_int32_t, + pub ifi_poll_off_err: u_int32_t, + pub ifi_poll_on_req: u_int32_t, + pub ifi_poll_on_err: u_int32_t, + pub ifi_poll_wakeups_avg: u_int32_t, + pub ifi_poll_wakeups_lowat: u_int32_t, + pub ifi_poll_wakeups_hiwat: u_int32_t, + pub ifi_poll_packets: u_int64_t, + pub ifi_poll_packets_avg: u_int32_t, + pub ifi_poll_packets_min: u_int32_t, + pub ifi_poll_packets_max: u_int32_t, + pub ifi_poll_packets_lowat: u_int32_t, + pub ifi_poll_packets_hiwat: u_int32_t, + pub ifi_poll_bytes: u_int64_t, + pub ifi_poll_bytes_avg: u_int32_t, + pub ifi_poll_bytes_min: u_int32_t, + pub ifi_poll_bytes_max: u_int32_t, + pub ifi_poll_bytes_lowat: u_int32_t, + pub ifi_poll_bytes_hiwat: u_int32_t, + pub ifi_poll_packets_limit: u_int32_t, + pub ifi_poll_interval_time: u_int64_t, +} +#[test] +fn bindgen_test_layout_if_rxpoll_stats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(if_rxpoll_stats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_rxpoll_stats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_off_req) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_off_req) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_off_err) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_off_err) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_on_req) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_on_req) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_on_err) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_on_err) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_wakeups_avg) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_wakeups_avg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_wakeups_lowat) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_wakeups_lowat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_wakeups_hiwat) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_wakeups_hiwat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_packets) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_packets_avg) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_packets_avg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_packets_min) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_packets_min) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_packets_max) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_packets_max) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_packets_lowat) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_packets_lowat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_packets_hiwat) as usize - ptr as usize }, + 52usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_packets_hiwat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_bytes) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_bytes_avg) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_bytes_avg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_bytes_min) as usize - ptr as usize }, + 68usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_bytes_min) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_bytes_max) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_bytes_max) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_bytes_lowat) as usize - ptr as usize }, + 76usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_bytes_lowat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_bytes_hiwat) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_bytes_hiwat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_packets_limit) as usize - ptr as usize }, + 84usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_packets_limit) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_poll_interval_time) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_rxpoll_stats), + "::", + stringify!(ifi_poll_interval_time) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_netif_stats { + pub ifn_rx_mit_interval: u_int64_t, + pub ifn_rx_mit_mode: u_int32_t, + pub ifn_rx_mit_packets_avg: u_int32_t, + pub ifn_rx_mit_packets_min: u_int32_t, + pub ifn_rx_mit_packets_max: u_int32_t, + pub ifn_rx_mit_bytes_avg: u_int32_t, + pub ifn_rx_mit_bytes_min: u_int32_t, + pub ifn_rx_mit_bytes_max: u_int32_t, + pub ifn_rx_mit_cfg_idx: u_int32_t, + pub ifn_rx_mit_cfg_packets_lowat: u_int32_t, + pub ifn_rx_mit_cfg_packets_hiwat: u_int32_t, + pub ifn_rx_mit_cfg_bytes_lowat: u_int32_t, + pub ifn_rx_mit_cfg_bytes_hiwat: u_int32_t, + pub ifn_rx_mit_cfg_interval: u_int32_t, +} +#[test] +fn bindgen_test_layout_if_netif_stats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 60usize, + concat!("Size of: ", stringify!(if_netif_stats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_netif_stats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_interval) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_interval) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_mode) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_mode) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_packets_avg) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_packets_avg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_packets_min) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_packets_min) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_packets_max) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_packets_max) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_bytes_avg) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_bytes_avg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_bytes_min) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_bytes_min) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_bytes_max) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_bytes_max) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_cfg_idx) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_cfg_idx) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_cfg_packets_lowat) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_cfg_packets_lowat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_cfg_packets_hiwat) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_cfg_packets_hiwat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_cfg_bytes_lowat) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_cfg_bytes_lowat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_cfg_bytes_hiwat) as usize - ptr as usize }, + 52usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_cfg_bytes_hiwat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifn_rx_mit_cfg_interval) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_netif_stats), + "::", + stringify!(ifn_rx_mit_cfg_interval) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_tcp_ecn_perf_stat { + pub total_txpkts: u_int64_t, + pub total_rxmitpkts: u_int64_t, + pub total_rxpkts: u_int64_t, + pub total_oopkts: u_int64_t, + pub total_reorderpkts: u_int64_t, + pub rtt_avg: u_int64_t, + pub rtt_var: u_int64_t, + pub sack_episodes: u_int64_t, + pub rxmit_drop: u_int64_t, + pub rst_drop: u_int64_t, + pub oo_percent: u_int64_t, + pub reorder_percent: u_int64_t, + pub rxmit_percent: u_int64_t, +} +#[test] +fn bindgen_test_layout_if_tcp_ecn_perf_stat() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 104usize, + concat!("Size of: ", stringify!(if_tcp_ecn_perf_stat)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_tcp_ecn_perf_stat)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).total_txpkts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(total_txpkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).total_rxmitpkts) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(total_rxmitpkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).total_rxpkts) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(total_rxpkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).total_oopkts) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(total_oopkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).total_reorderpkts) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(total_reorderpkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtt_avg) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(rtt_avg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtt_var) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(rtt_var) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sack_episodes) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(sack_episodes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxmit_drop) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(rxmit_drop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rst_drop) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(rst_drop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).oo_percent) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(oo_percent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reorder_percent) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(reorder_percent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxmit_percent) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_perf_stat), + "::", + stringify!(rxmit_percent) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_tcp_ecn_stat { + pub timestamp: u_int64_t, + pub ecn_client_setup: u_int64_t, + pub ecn_server_setup: u_int64_t, + pub ecn_client_success: u_int64_t, + pub ecn_server_success: u_int64_t, + pub ecn_peer_nosupport: u_int64_t, + pub ecn_syn_lost: u_int64_t, + pub ecn_synack_lost: u_int64_t, + pub ecn_recv_ce: u_int64_t, + pub ecn_recv_ece: u_int64_t, + pub ecn_conn_recv_ce: u_int64_t, + pub ecn_conn_recv_ece: u_int64_t, + pub ecn_conn_plnoce: u_int64_t, + pub ecn_conn_plce: u_int64_t, + pub ecn_conn_noplce: u_int64_t, + pub ecn_fallback_synloss: u_int64_t, + pub ecn_fallback_reorder: u_int64_t, + pub ecn_fallback_ce: u_int64_t, + pub ecn_off_conn: u_int64_t, + pub ecn_total_conn: u_int64_t, + pub ecn_fallback_droprst: u_int64_t, + pub ecn_fallback_droprxmt: u_int64_t, + pub ecn_fallback_synrst: u_int64_t, + pub ecn_on: if_tcp_ecn_perf_stat, + pub ecn_off: if_tcp_ecn_perf_stat, +} +#[test] +fn bindgen_test_layout_if_tcp_ecn_stat() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 392usize, + concat!("Size of: ", stringify!(if_tcp_ecn_stat)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_tcp_ecn_stat)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timestamp) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(timestamp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_client_setup) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_client_setup) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_server_setup) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_server_setup) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_client_success) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_client_success) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_server_success) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_server_success) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_peer_nosupport) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_peer_nosupport) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_syn_lost) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_syn_lost) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_synack_lost) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_synack_lost) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_recv_ce) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_recv_ce) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_recv_ece) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_recv_ece) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_conn_recv_ce) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_conn_recv_ce) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_conn_recv_ece) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_conn_recv_ece) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_conn_plnoce) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_conn_plnoce) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_conn_plce) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_conn_plce) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_conn_noplce) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_conn_noplce) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_fallback_synloss) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_fallback_synloss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_fallback_reorder) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_fallback_reorder) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_fallback_ce) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_fallback_ce) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_off_conn) as usize - ptr as usize }, + 144usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_off_conn) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_total_conn) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_total_conn) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_fallback_droprst) as usize - ptr as usize }, + 160usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_fallback_droprst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_fallback_droprxmt) as usize - ptr as usize }, + 168usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_fallback_droprxmt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_fallback_synrst) as usize - ptr as usize }, + 176usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_fallback_synrst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_on) as usize - ptr as usize }, + 184usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_on) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_off) as usize - ptr as usize }, + 288usize, + concat!( + "Offset of field: ", + stringify!(if_tcp_ecn_stat), + "::", + stringify!(ecn_off) + ) + ); +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct if_lim_perf_stat { + pub lim_dl_max_bandwidth: u_int64_t, + pub lim_ul_max_bandwidth: u_int64_t, + pub lim_total_txpkts: u_int64_t, + pub lim_total_rxpkts: u_int64_t, + pub lim_total_retxpkts: u_int64_t, + pub lim_packet_loss_percent: u_int64_t, + pub lim_total_oopkts: u_int64_t, + pub lim_packet_ooo_percent: u_int64_t, + pub lim_rtt_variance: u_int64_t, + pub lim_rtt_average: u_int64_t, + pub lim_rtt_min: u_int64_t, + pub lim_conn_timeouts: u_int64_t, + pub lim_conn_attempts: u_int64_t, + pub lim_conn_timeout_percent: u_int64_t, + pub lim_bk_txpkts: u_int64_t, + pub _bitfield_align_1: [u8; 0], + pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>, + pub __bindgen_padding_0: [u8; 3usize], +} +#[test] +fn bindgen_test_layout_if_lim_perf_stat() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 124usize, + concat!("Size of: ", stringify!(if_lim_perf_stat)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_lim_perf_stat)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_dl_max_bandwidth) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_dl_max_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_ul_max_bandwidth) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_ul_max_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_total_txpkts) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_total_txpkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_total_rxpkts) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_total_rxpkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_total_retxpkts) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_total_retxpkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_packet_loss_percent) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_packet_loss_percent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_total_oopkts) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_total_oopkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_packet_ooo_percent) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_packet_ooo_percent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_rtt_variance) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_rtt_variance) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_rtt_average) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_rtt_average) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_rtt_min) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_rtt_min) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_conn_timeouts) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_conn_timeouts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_conn_attempts) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_conn_attempts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_conn_timeout_percent) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_conn_timeout_percent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lim_bk_txpkts) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(if_lim_perf_stat), + "::", + stringify!(lim_bk_txpkts) + ) + ); +} +impl if_lim_perf_stat { + #[inline] + pub fn lim_dl_detected(&self) -> u_int64_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) } + } + + #[inline] + pub fn set_lim_dl_detected(&mut self, val: u_int64_t) { + unsafe { + let val: u64 = ::std::mem::transmute(val); + self._bitfield_1.set(0usize, 1u8, val as u64) + } + } + + #[inline] + pub fn lim_ul_detected(&self) -> u_int64_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u64) } + } + + #[inline] + pub fn set_lim_ul_detected(&mut self, val: u_int64_t) { + unsafe { + let val: u64 = ::std::mem::transmute(val); + self._bitfield_1.set(1usize, 1u8, val as u64) + } + } + + #[inline] + pub fn new_bitfield_1( + lim_dl_detected: u_int64_t, + lim_ul_detected: u_int64_t, + ) -> __BindgenBitfieldUnit<[u8; 1usize]> { + let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize]> = Default::default(); + __bindgen_bitfield_unit.set(0usize, 1u8, { + let lim_dl_detected: u64 = unsafe { ::std::mem::transmute(lim_dl_detected) }; + lim_dl_detected as u64 + }); + __bindgen_bitfield_unit.set(1usize, 1u8, { + let lim_ul_detected: u64 = unsafe { ::std::mem::transmute(lim_ul_detected) }; + lim_ul_detected as u64 + }); + __bindgen_bitfield_unit + } +} +#[repr(C, packed(4))] +#[derive(Debug, Copy, Clone)] +pub struct ifnet_stats_per_flow { + pub bk_txpackets: u_int64_t, + pub txpackets: u_int64_t, + pub rxpackets: u_int64_t, + pub txretransmitbytes: u_int32_t, + pub rxoutoforderbytes: u_int32_t, + pub rxmitpkts: u_int32_t, + pub rcvoopack: u_int32_t, + pub pawsdrop: u_int32_t, + pub sack_recovery_episodes: u_int32_t, + pub reordered_pkts: u_int32_t, + pub dsack_sent: u_int32_t, + pub dsack_recvd: u_int32_t, + pub srtt: u_int32_t, + pub rttupdated: u_int32_t, + pub rttvar: u_int32_t, + pub rttmin: u_int32_t, + pub bw_sndbw_max: u_int32_t, + pub bw_rcvbw_max: u_int32_t, + pub ecn_recv_ece: u_int32_t, + pub ecn_recv_ce: u_int32_t, + pub ecn_flags: u_int16_t, + pub _bitfield_align_1: [u8; 0], + pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>, +} +#[test] +fn bindgen_test_layout_ifnet_stats_per_flow() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(ifnet_stats_per_flow)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifnet_stats_per_flow)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bk_txpackets) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(bk_txpackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).txpackets) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(txpackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxpackets) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(rxpackets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).txretransmitbytes) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(txretransmitbytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxoutoforderbytes) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(rxoutoforderbytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxmitpkts) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(rxmitpkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rcvoopack) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(rcvoopack) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pawsdrop) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(pawsdrop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sack_recovery_episodes) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(sack_recovery_episodes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reordered_pkts) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(reordered_pkts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dsack_sent) as usize - ptr as usize }, + 52usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(dsack_sent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dsack_recvd) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(dsack_recvd) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).srtt) as usize - ptr as usize }, + 60usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(srtt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rttupdated) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(rttupdated) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rttvar) as usize - ptr as usize }, + 68usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(rttvar) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rttmin) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(rttmin) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bw_sndbw_max) as usize - ptr as usize }, + 76usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(bw_sndbw_max) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bw_rcvbw_max) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(bw_rcvbw_max) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_recv_ece) as usize - ptr as usize }, + 84usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(ecn_recv_ece) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_recv_ce) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(ecn_recv_ce) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ecn_flags) as usize - ptr as usize }, + 92usize, + concat!( + "Offset of field: ", + stringify!(ifnet_stats_per_flow), + "::", + stringify!(ecn_flags) + ) + ); +} +impl ifnet_stats_per_flow { + #[inline] + pub fn ipv4(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u16) } + } + + #[inline] + pub fn set_ipv4(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(0usize, 1u8, val as u64) + } + } + + #[inline] + pub fn local(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u16) } + } + + #[inline] + pub fn set_local(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(1usize, 1u8, val as u64) + } + } + + #[inline] + pub fn connreset(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u16) } + } + + #[inline] + pub fn set_connreset(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(2usize, 1u8, val as u64) + } + } + + #[inline] + pub fn conntimeout(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u16) } + } + + #[inline] + pub fn set_conntimeout(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(3usize, 1u8, val as u64) + } + } + + #[inline] + pub fn rxmit_drop(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u16) } + } + + #[inline] + pub fn set_rxmit_drop(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(4usize, 1u8, val as u64) + } + } + + #[inline] + pub fn ecn_fallback_synloss(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u16) } + } + + #[inline] + pub fn set_ecn_fallback_synloss(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(5usize, 1u8, val as u64) + } + } + + #[inline] + pub fn ecn_fallback_droprst(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 1u8) as u16) } + } + + #[inline] + pub fn set_ecn_fallback_droprst(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(6usize, 1u8, val as u64) + } + } + + #[inline] + pub fn ecn_fallback_droprxmt(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u16) } + } + + #[inline] + pub fn set_ecn_fallback_droprxmt(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(7usize, 1u8, val as u64) + } + } + + #[inline] + pub fn ecn_fallback_ce(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 1u8) as u16) } + } + + #[inline] + pub fn set_ecn_fallback_ce(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(8usize, 1u8, val as u64) + } + } + + #[inline] + pub fn ecn_fallback_reorder(&self) -> u_int16_t { + unsafe { ::std::mem::transmute(self._bitfield_1.get(9usize, 1u8) as u16) } + } + + #[inline] + pub fn set_ecn_fallback_reorder(&mut self, val: u_int16_t) { + unsafe { + let val: u16 = ::std::mem::transmute(val); + self._bitfield_1.set(9usize, 1u8, val as u64) + } + } + + #[inline] + pub fn new_bitfield_1( + ipv4: u_int16_t, + local: u_int16_t, + connreset: u_int16_t, + conntimeout: u_int16_t, + rxmit_drop: u_int16_t, + ecn_fallback_synloss: u_int16_t, + ecn_fallback_droprst: u_int16_t, + ecn_fallback_droprxmt: u_int16_t, + ecn_fallback_ce: u_int16_t, + ecn_fallback_reorder: u_int16_t, + ) -> __BindgenBitfieldUnit<[u8; 2usize]> { + let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 2usize]> = Default::default(); + __bindgen_bitfield_unit.set(0usize, 1u8, { + let ipv4: u16 = unsafe { ::std::mem::transmute(ipv4) }; + ipv4 as u64 + }); + __bindgen_bitfield_unit.set(1usize, 1u8, { + let local: u16 = unsafe { ::std::mem::transmute(local) }; + local as u64 + }); + __bindgen_bitfield_unit.set(2usize, 1u8, { + let connreset: u16 = unsafe { ::std::mem::transmute(connreset) }; + connreset as u64 + }); + __bindgen_bitfield_unit.set(3usize, 1u8, { + let conntimeout: u16 = unsafe { ::std::mem::transmute(conntimeout) }; + conntimeout as u64 + }); + __bindgen_bitfield_unit.set(4usize, 1u8, { + let rxmit_drop: u16 = unsafe { ::std::mem::transmute(rxmit_drop) }; + rxmit_drop as u64 + }); + __bindgen_bitfield_unit.set(5usize, 1u8, { + let ecn_fallback_synloss: u16 = unsafe { ::std::mem::transmute(ecn_fallback_synloss) }; + ecn_fallback_synloss as u64 + }); + __bindgen_bitfield_unit.set(6usize, 1u8, { + let ecn_fallback_droprst: u16 = unsafe { ::std::mem::transmute(ecn_fallback_droprst) }; + ecn_fallback_droprst as u64 + }); + __bindgen_bitfield_unit.set(7usize, 1u8, { + let ecn_fallback_droprxmt: u16 = unsafe { ::std::mem::transmute(ecn_fallback_droprxmt) }; + ecn_fallback_droprxmt as u64 + }); + __bindgen_bitfield_unit.set(8usize, 1u8, { + let ecn_fallback_ce: u16 = unsafe { ::std::mem::transmute(ecn_fallback_ce) }; + ecn_fallback_ce as u64 + }); + __bindgen_bitfield_unit.set(9usize, 1u8, { + let ecn_fallback_reorder: u16 = unsafe { ::std::mem::transmute(ecn_fallback_reorder) }; + ecn_fallback_reorder as u64 + }); + __bindgen_bitfield_unit + } +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct if_cellular_status_v1 { + pub valid_bitmask: u_int32_t, + pub link_quality_metric: u_int32_t, + pub ul_effective_bandwidth: u_int32_t, + pub ul_max_bandwidth: u_int32_t, + pub ul_min_latency: u_int32_t, + pub ul_effective_latency: u_int32_t, + pub ul_max_latency: u_int32_t, + pub ul_retxt_level: u_int32_t, + pub ul_bytes_lost: u_int32_t, + pub ul_min_queue_size: u_int32_t, + pub ul_avg_queue_size: u_int32_t, + pub ul_max_queue_size: u_int32_t, + pub dl_effective_bandwidth: u_int32_t, + pub dl_max_bandwidth: u_int32_t, + pub config_inactivity_time: u_int32_t, + pub config_backoff_time: u_int32_t, + pub mss_recommended: u_int16_t, + pub reserved_1: u_int16_t, + pub reserved_2: u_int32_t, + pub reserved_3: u_int64_t, + pub reserved_4: u_int64_t, + pub reserved_5: u_int64_t, + pub reserved_6: u_int64_t, +} +#[test] +fn bindgen_test_layout_if_cellular_status_v1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 104usize, + concat!("Size of: ", stringify!(if_cellular_status_v1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_cellular_status_v1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).valid_bitmask) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(valid_bitmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).link_quality_metric) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(link_quality_metric) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_effective_bandwidth) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_effective_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_max_bandwidth) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_max_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_min_latency) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_min_latency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_effective_latency) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_effective_latency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_max_latency) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_max_latency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_retxt_level) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_retxt_level) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_bytes_lost) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_bytes_lost) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_min_queue_size) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_min_queue_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_avg_queue_size) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_avg_queue_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_max_queue_size) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(ul_max_queue_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dl_effective_bandwidth) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(dl_effective_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dl_max_bandwidth) as usize - ptr as usize }, + 52usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(dl_max_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).config_inactivity_time) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(config_inactivity_time) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).config_backoff_time) as usize - ptr as usize }, + 60usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(config_backoff_time) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mss_recommended) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(mss_recommended) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_1) as usize - ptr as usize }, + 66usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(reserved_1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_2) as usize - ptr as usize }, + 68usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(reserved_2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_3) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(reserved_3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_4) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(reserved_4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_5) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(reserved_5) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_6) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status_v1), + "::", + stringify!(reserved_6) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct if_cellular_status { + pub if_cell_u: if_cellular_status__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union if_cellular_status__bindgen_ty_1 { + pub if_status_v1: if_cellular_status_v1, +} +#[test] +fn bindgen_test_layout_if_cellular_status__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 104usize, + concat!("Size of: ", stringify!(if_cellular_status__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_cellular_status__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_status_v1) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status__bindgen_ty_1), + "::", + stringify!(if_status_v1) + ) + ); +} +#[test] +fn bindgen_test_layout_if_cellular_status() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 104usize, + concat!("Size of: ", stringify!(if_cellular_status)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_cellular_status)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_cell_u) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_cellular_status), + "::", + stringify!(if_cell_u) + ) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct if_wifi_status_v1 { + pub valid_bitmask: u_int32_t, + pub link_quality_metric: u_int32_t, + pub ul_effective_bandwidth: u_int32_t, + pub ul_max_bandwidth: u_int32_t, + pub ul_min_latency: u_int32_t, + pub ul_effective_latency: u_int32_t, + pub ul_max_latency: u_int32_t, + pub ul_retxt_level: u_int32_t, + pub ul_bytes_lost: u_int32_t, + pub ul_error_rate: u_int32_t, + pub dl_effective_bandwidth: u_int32_t, + pub dl_max_bandwidth: u_int32_t, + pub dl_min_latency: u_int32_t, + pub dl_effective_latency: u_int32_t, + pub dl_max_latency: u_int32_t, + pub dl_error_rate: u_int32_t, + pub config_frequency: u_int32_t, + pub config_multicast_rate: u_int32_t, + pub scan_count: u_int32_t, + pub scan_duration: u_int32_t, + pub reserved_1: u_int64_t, + pub reserved_2: u_int64_t, + pub reserved_3: u_int64_t, + pub reserved_4: u_int64_t, +} +#[test] +fn bindgen_test_layout_if_wifi_status_v1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 112usize, + concat!("Size of: ", stringify!(if_wifi_status_v1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_wifi_status_v1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).valid_bitmask) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(valid_bitmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).link_quality_metric) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(link_quality_metric) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_effective_bandwidth) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(ul_effective_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_max_bandwidth) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(ul_max_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_min_latency) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(ul_min_latency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_effective_latency) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(ul_effective_latency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_max_latency) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(ul_max_latency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_retxt_level) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(ul_retxt_level) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_bytes_lost) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(ul_bytes_lost) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ul_error_rate) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(ul_error_rate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dl_effective_bandwidth) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(dl_effective_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dl_max_bandwidth) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(dl_max_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dl_min_latency) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(dl_min_latency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dl_effective_latency) as usize - ptr as usize }, + 52usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(dl_effective_latency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dl_max_latency) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(dl_max_latency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dl_error_rate) as usize - ptr as usize }, + 60usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(dl_error_rate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).config_frequency) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(config_frequency) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).config_multicast_rate) as usize - ptr as usize }, + 68usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(config_multicast_rate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scan_count) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(scan_count) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scan_duration) as usize - ptr as usize }, + 76usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(scan_duration) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_1) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(reserved_1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_2) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(reserved_2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_3) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(reserved_3) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_4) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status_v1), + "::", + stringify!(reserved_4) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct if_wifi_status { + pub if_wifi_u: if_wifi_status__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union if_wifi_status__bindgen_ty_1 { + pub if_status_v1: if_wifi_status_v1, +} +#[test] +fn bindgen_test_layout_if_wifi_status__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 112usize, + concat!("Size of: ", stringify!(if_wifi_status__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_wifi_status__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_status_v1) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status__bindgen_ty_1), + "::", + stringify!(if_status_v1) + ) + ); +} +#[test] +fn bindgen_test_layout_if_wifi_status() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 112usize, + concat!("Size of: ", stringify!(if_wifi_status)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_wifi_status)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_wifi_u) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_wifi_status), + "::", + stringify!(if_wifi_u) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct if_link_status { + pub ifsr_version: u_int32_t, + pub ifsr_len: u_int32_t, + pub ifsr_u: if_link_status__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union if_link_status__bindgen_ty_1 { + pub ifsr_cell: if_cellular_status, + pub ifsr_wifi: if_wifi_status, +} +#[test] +fn bindgen_test_layout_if_link_status__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 112usize, + concat!("Size of: ", stringify!(if_link_status__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_link_status__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifsr_cell) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_link_status__bindgen_ty_1), + "::", + stringify!(ifsr_cell) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifsr_wifi) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_link_status__bindgen_ty_1), + "::", + stringify!(ifsr_wifi) + ) + ); +} +#[test] +fn bindgen_test_layout_if_link_status() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 120usize, + concat!("Size of: ", stringify!(if_link_status)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_link_status)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifsr_version) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_link_status), + "::", + stringify!(ifsr_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifsr_len) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_link_status), + "::", + stringify!(ifsr_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifsr_u) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_link_status), + "::", + stringify!(ifsr_u) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_interface_state { + pub valid_bitmask: u_int8_t, + pub rrc_state: u_int8_t, + pub lqm_state: i8, + pub interface_availability: u_int8_t, +} +#[test] +fn bindgen_test_layout_if_interface_state() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(if_interface_state)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_interface_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).valid_bitmask) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_interface_state), + "::", + stringify!(valid_bitmask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rrc_state) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(if_interface_state), + "::", + stringify!(rrc_state) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lqm_state) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(if_interface_state), + "::", + stringify!(lqm_state) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).interface_availability) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(if_interface_state), + "::", + stringify!(interface_availability) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct chain_len_stats { + pub cls_one: u64, + pub cls_two: u64, + pub cls_three: u64, + pub cls_four: u64, + pub cls_five_or_more: u64, +} +#[test] +fn bindgen_test_layout_chain_len_stats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(chain_len_stats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(chain_len_stats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cls_one) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(chain_len_stats), + "::", + stringify!(cls_one) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cls_two) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(chain_len_stats), + "::", + stringify!(cls_two) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cls_three) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(chain_len_stats), + "::", + stringify!(cls_three) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cls_four) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(chain_len_stats), + "::", + stringify!(cls_four) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cls_five_or_more) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(chain_len_stats), + "::", + stringify!(cls_five_or_more) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifnet_interface_advisory { + pub version: u8, + pub direction: u8, + pub _reserved: u16, + pub rate_trend_suggestion: i32, + pub timestamp: u64, + pub max_bandwidth: u64, + pub total_byte_count: u64, + pub average_throughput: u64, + pub flushable_queue_size: u32, + pub non_flushable_queue_size: u32, + pub average_delay: u32, +} +#[test] +fn bindgen_test_layout_ifnet_interface_advisory() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(ifnet_interface_advisory)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifnet_interface_advisory)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(direction) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._reserved) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(_reserved) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rate_trend_suggestion) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(rate_trend_suggestion) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timestamp) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(timestamp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_bandwidth) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(max_bandwidth) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).total_byte_count) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(total_byte_count) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).average_throughput) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(average_throughput) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flushable_queue_size) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(flushable_queue_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).non_flushable_queue_size) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(non_flushable_queue_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).average_delay) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(ifnet_interface_advisory), + "::", + stringify!(average_delay) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifqueue { + pub ifq_head: *mut ::std::os::raw::c_void, + pub ifq_tail: *mut ::std::os::raw::c_void, + pub ifq_len: ::std::os::raw::c_int, + pub ifq_maxlen: ::std::os::raw::c_int, + pub ifq_drops: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ifqueue() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(ifqueue)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifqueue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifq_head) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifqueue), "::", stringify!(ifq_head)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifq_tail) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(ifqueue), "::", stringify!(ifq_tail)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifq_len) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifqueue), "::", stringify!(ifq_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifq_maxlen) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(ifqueue), "::", stringify!(ifq_maxlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifq_drops) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(ifqueue), "::", stringify!(ifq_drops)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union sockaddr_union { + pub sa: sockaddr, + pub sin: sockaddr_in, + pub sin6: sockaddr_in6, +} +#[test] +fn bindgen_test_layout_sockaddr_union() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 28usize, + concat!("Size of: ", stringify!(sockaddr_union)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_union)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_union), "::", stringify!(sa)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_union), "::", stringify!(sin)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_union), "::", stringify!(sin6)) + ); +} +pub const PF_INOUT: _bindgen_ty_1 = 0; +pub const PF_IN: _bindgen_ty_1 = 1; +pub const PF_OUT: _bindgen_ty_1 = 2; +pub type _bindgen_ty_1 = ::std::os::raw::c_uint; +pub const PF_PASS: _bindgen_ty_2 = 0; +pub const PF_DROP: _bindgen_ty_2 = 1; +pub const PF_SCRUB: _bindgen_ty_2 = 2; +pub const PF_NOSCRUB: _bindgen_ty_2 = 3; +pub const PF_NAT: _bindgen_ty_2 = 4; +pub const PF_NONAT: _bindgen_ty_2 = 5; +pub const PF_BINAT: _bindgen_ty_2 = 6; +pub const PF_NOBINAT: _bindgen_ty_2 = 7; +pub const PF_RDR: _bindgen_ty_2 = 8; +pub const PF_NORDR: _bindgen_ty_2 = 9; +pub const PF_SYNPROXY_DROP: _bindgen_ty_2 = 10; +pub const PF_DUMMYNET: _bindgen_ty_2 = 11; +pub const PF_NODUMMYNET: _bindgen_ty_2 = 12; +pub const PF_NAT64: _bindgen_ty_2 = 13; +pub const PF_NONAT64: _bindgen_ty_2 = 14; +pub type _bindgen_ty_2 = ::std::os::raw::c_uint; +pub const PF_RULESET_SCRUB: _bindgen_ty_3 = 0; +pub const PF_RULESET_FILTER: _bindgen_ty_3 = 1; +pub const PF_RULESET_NAT: _bindgen_ty_3 = 2; +pub const PF_RULESET_BINAT: _bindgen_ty_3 = 3; +pub const PF_RULESET_RDR: _bindgen_ty_3 = 4; +pub const PF_RULESET_DUMMYNET: _bindgen_ty_3 = 5; +pub const PF_RULESET_MAX: _bindgen_ty_3 = 6; +pub type _bindgen_ty_3 = ::std::os::raw::c_uint; +pub const PF_OP_NONE: _bindgen_ty_4 = 0; +pub const PF_OP_IRG: _bindgen_ty_4 = 1; +pub const PF_OP_EQ: _bindgen_ty_4 = 2; +pub const PF_OP_NE: _bindgen_ty_4 = 3; +pub const PF_OP_LT: _bindgen_ty_4 = 4; +pub const PF_OP_LE: _bindgen_ty_4 = 5; +pub const PF_OP_GT: _bindgen_ty_4 = 6; +pub const PF_OP_GE: _bindgen_ty_4 = 7; +pub const PF_OP_XRG: _bindgen_ty_4 = 8; +pub const PF_OP_RRG: _bindgen_ty_4 = 9; +pub type _bindgen_ty_4 = ::std::os::raw::c_uint; +pub const PF_DEBUG_NONE: _bindgen_ty_5 = 0; +pub const PF_DEBUG_URGENT: _bindgen_ty_5 = 1; +pub const PF_DEBUG_MISC: _bindgen_ty_5 = 2; +pub const PF_DEBUG_NOISY: _bindgen_ty_5 = 3; +pub type _bindgen_ty_5 = ::std::os::raw::c_uint; +pub const PF_CHANGE_NONE: _bindgen_ty_6 = 0; +pub const PF_CHANGE_ADD_HEAD: _bindgen_ty_6 = 1; +pub const PF_CHANGE_ADD_TAIL: _bindgen_ty_6 = 2; +pub const PF_CHANGE_ADD_BEFORE: _bindgen_ty_6 = 3; +pub const PF_CHANGE_ADD_AFTER: _bindgen_ty_6 = 4; +pub const PF_CHANGE_REMOVE: _bindgen_ty_6 = 5; +pub const PF_CHANGE_GET_TICKET: _bindgen_ty_6 = 6; +pub type _bindgen_ty_6 = ::std::os::raw::c_uint; +pub const PF_GET_NONE: _bindgen_ty_7 = 0; +pub const PF_GET_CLR_CNTR: _bindgen_ty_7 = 1; +pub type _bindgen_ty_7 = ::std::os::raw::c_uint; +pub const PFTM_TCP_FIRST_PACKET: _bindgen_ty_8 = 0; +pub const PFTM_TCP_OPENING: _bindgen_ty_8 = 1; +pub const PFTM_TCP_ESTABLISHED: _bindgen_ty_8 = 2; +pub const PFTM_TCP_CLOSING: _bindgen_ty_8 = 3; +pub const PFTM_TCP_FIN_WAIT: _bindgen_ty_8 = 4; +pub const PFTM_TCP_CLOSED: _bindgen_ty_8 = 5; +pub const PFTM_UDP_FIRST_PACKET: _bindgen_ty_8 = 6; +pub const PFTM_UDP_SINGLE: _bindgen_ty_8 = 7; +pub const PFTM_UDP_MULTIPLE: _bindgen_ty_8 = 8; +pub const PFTM_ICMP_FIRST_PACKET: _bindgen_ty_8 = 9; +pub const PFTM_ICMP_ERROR_REPLY: _bindgen_ty_8 = 10; +pub const PFTM_GREv1_FIRST_PACKET: _bindgen_ty_8 = 11; +pub const PFTM_GREv1_INITIATING: _bindgen_ty_8 = 12; +pub const PFTM_GREv1_ESTABLISHED: _bindgen_ty_8 = 13; +pub const PFTM_ESP_FIRST_PACKET: _bindgen_ty_8 = 14; +pub const PFTM_ESP_INITIATING: _bindgen_ty_8 = 15; +pub const PFTM_ESP_ESTABLISHED: _bindgen_ty_8 = 16; +pub const PFTM_OTHER_FIRST_PACKET: _bindgen_ty_8 = 17; +pub const PFTM_OTHER_SINGLE: _bindgen_ty_8 = 18; +pub const PFTM_OTHER_MULTIPLE: _bindgen_ty_8 = 19; +pub const PFTM_FRAG: _bindgen_ty_8 = 20; +pub const PFTM_INTERVAL: _bindgen_ty_8 = 21; +pub const PFTM_ADAPTIVE_START: _bindgen_ty_8 = 22; +pub const PFTM_ADAPTIVE_END: _bindgen_ty_8 = 23; +pub const PFTM_SRC_NODE: _bindgen_ty_8 = 24; +pub const PFTM_TS_DIFF: _bindgen_ty_8 = 25; +pub const PFTM_MAX: _bindgen_ty_8 = 26; +pub const PFTM_PURGE: _bindgen_ty_8 = 27; +pub const PFTM_UNLINKED: _bindgen_ty_8 = 28; +pub type _bindgen_ty_8 = ::std::os::raw::c_uint; +pub const PF_NOPFROUTE: _bindgen_ty_9 = 0; +pub const PF_FASTROUTE: _bindgen_ty_9 = 1; +pub const PF_ROUTETO: _bindgen_ty_9 = 2; +pub const PF_DUPTO: _bindgen_ty_9 = 3; +pub const PF_REPLYTO: _bindgen_ty_9 = 4; +pub type _bindgen_ty_9 = ::std::os::raw::c_uint; +pub const PF_LIMIT_STATES: _bindgen_ty_10 = 0; +pub const PF_LIMIT_APP_STATES: _bindgen_ty_10 = 1; +pub const PF_LIMIT_SRC_NODES: _bindgen_ty_10 = 2; +pub const PF_LIMIT_FRAGS: _bindgen_ty_10 = 3; +pub const PF_LIMIT_TABLES: _bindgen_ty_10 = 4; +pub const PF_LIMIT_TABLE_ENTRIES: _bindgen_ty_10 = 5; +pub const PF_LIMIT_MAX: _bindgen_ty_10 = 6; +pub type _bindgen_ty_10 = ::std::os::raw::c_uint; +pub const PF_POOL_NONE: _bindgen_ty_11 = 0; +pub const PF_POOL_BITMASK: _bindgen_ty_11 = 1; +pub const PF_POOL_RANDOM: _bindgen_ty_11 = 2; +pub const PF_POOL_SRCHASH: _bindgen_ty_11 = 3; +pub const PF_POOL_ROUNDROBIN: _bindgen_ty_11 = 4; +pub type _bindgen_ty_11 = ::std::os::raw::c_uint; +pub const PF_ADDR_ADDRMASK: _bindgen_ty_12 = 0; +pub const PF_ADDR_NOROUTE: _bindgen_ty_12 = 1; +pub const PF_ADDR_DYNIFTL: _bindgen_ty_12 = 2; +pub const PF_ADDR_TABLE: _bindgen_ty_12 = 3; +pub const PF_ADDR_RTLABEL: _bindgen_ty_12 = 4; +pub const PF_ADDR_URPFFAILED: _bindgen_ty_12 = 5; +pub const PF_ADDR_RANGE: _bindgen_ty_12 = 6; +pub type _bindgen_ty_12 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_addr { + pub pfa: pf_addr__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_addr__bindgen_ty_1 { + pub _v4addr: in_addr, + pub _v6addr: in6_addr, + pub _addr8: [u_int8_t; 16usize], + pub _addr16: [u_int16_t; 8usize], + pub _addr32: [u_int32_t; 4usize], +} +#[test] +fn bindgen_test_layout_pf_addr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_addr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._v4addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(_v4addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._v6addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(_v6addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._addr8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(_addr8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._addr16) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(_addr16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._addr32) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(_addr32) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfa) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_addr), "::", stringify!(pfa)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_addr_wrap { + pub v: pf_addr_wrap__bindgen_ty_1, + pub p: pf_addr_wrap__bindgen_ty_2, + pub type_: u_int8_t, + pub iflags: u_int8_t, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_addr_wrap__bindgen_ty_1 { + pub a: pf_addr_wrap__bindgen_ty_1__bindgen_ty_1, + pub ifname: [::std::os::raw::c_char; 16usize], + pub tblname: [::std::os::raw::c_char; 32usize], + pub rtlabelname: [::std::os::raw::c_char; 32usize], + pub rtlabel: u_int32_t, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_addr_wrap__bindgen_ty_1__bindgen_ty_1 { + pub addr: pf_addr, + pub mask: pf_addr, +} +#[test] +fn bindgen_test_layout_pf_addr_wrap__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mask) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(mask) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_addr_wrap__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_addr_wrap__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr_wrap__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).a) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(a) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tblname) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(tblname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtlabelname) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(rtlabelname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtlabel) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(rtlabel) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_addr_wrap__bindgen_ty_2 { + pub dyn_: *mut ::std::os::raw::c_void, + pub tbl: *mut ::std::os::raw::c_void, + pub dyncnt: ::std::os::raw::c_int, + pub tblcnt: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_addr_wrap__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_addr_wrap__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_addr_wrap__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dyn_) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(dyn_) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tbl) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(tbl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dyncnt) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(dyncnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tblcnt) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(tblcnt) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_addr_wrap() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(pf_addr_wrap)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_addr_wrap)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).v) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(v)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).p) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(p)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(type_)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iflags) as usize - ptr as usize }, + 41usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(iflags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_port_range { + pub port: [u_int16_t; 2usize], + pub op: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_port_range() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 6usize, + concat!("Size of: ", stringify!(pf_port_range)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(pf_port_range)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_port_range), "::", stringify!(port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).op) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pf_port_range), "::", stringify!(op)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_rule_xport { + pub range: pf_port_range, + pub call_id: u_int16_t, + pub spi: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_rule_xport() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_rule_xport)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule_xport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).range) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_xport), "::", stringify!(range)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).call_id) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_xport), + "::", + stringify!(call_id) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).spi) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_xport), "::", stringify!(spi)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_uid { + pub uid: [uid_t; 2usize], + pub op: u_int8_t, + pub _pad: [u_int8_t; 3usize], +} +#[test] +fn bindgen_test_layout_pf_rule_uid() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(pf_rule_uid)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule_uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_uid), "::", stringify!(uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).op) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_rule_uid), "::", stringify!(op)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pad) as usize - ptr as usize }, + 9usize, + concat!("Offset of field: ", stringify!(pf_rule_uid), "::", stringify!(_pad)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_gid { + pub gid: [uid_t; 2usize], + pub op: u_int8_t, + pub _pad: [u_int8_t; 3usize], +} +#[test] +fn bindgen_test_layout_pf_rule_gid() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(pf_rule_gid)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule_gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_gid), "::", stringify!(gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).op) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_rule_gid), "::", stringify!(op)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pad) as usize - ptr as usize }, + 9usize, + concat!("Offset of field: ", stringify!(pf_rule_gid), "::", stringify!(_pad)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_rule_addr { + pub addr: pf_addr_wrap, + pub xport: pf_rule_xport, + pub neg: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_rule_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(pf_rule_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).xport) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(xport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).neg) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(neg)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_pooladdr { + pub addr: pf_addr_wrap, + pub entries: pf_pooladdr__bindgen_ty_1, + pub ifname: [::std::os::raw::c_char; 16usize], + pub kif: *mut ::std::os::raw::c_void, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_pooladdr__bindgen_ty_1 { + pub tqe_next: *mut pf_pooladdr, + pub tqe_prev: *mut *mut pf_pooladdr, +} +#[test] +fn bindgen_test_layout_pf_pooladdr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_pooladdr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_pooladdr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_pooladdr__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_pooladdr__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_pooladdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 88usize, + concat!("Size of: ", stringify!(pf_pooladdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_pooladdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_pooladdr), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_pooladdr), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_pooladdr), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_pooladdr), "::", stringify!(kif)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_palist { + pub tqh_first: *mut pf_pooladdr, + pub tqh_last: *mut *mut pf_pooladdr, +} +#[test] +fn bindgen_test_layout_pf_palist() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_palist)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_palist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_palist), "::", stringify!(tqh_first)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_palist), "::", stringify!(tqh_last)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_poolhashkey { + pub pfk: pf_poolhashkey__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_poolhashkey__bindgen_ty_1 { + pub key8: [u_int8_t; 16usize], + pub key16: [u_int16_t; 8usize], + pub key32: [u_int32_t; 4usize], +} +#[test] +fn bindgen_test_layout_pf_poolhashkey__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_poolhashkey__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_poolhashkey__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_poolhashkey__bindgen_ty_1), + "::", + stringify!(key8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key16) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_poolhashkey__bindgen_ty_1), + "::", + stringify!(key16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key32) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_poolhashkey__bindgen_ty_1), + "::", + stringify!(key32) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_poolhashkey() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_poolhashkey)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_poolhashkey)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfk) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_poolhashkey), "::", stringify!(pfk)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_pool { + pub list: pf_palist, + pub cur: *mut ::std::os::raw::c_void, + pub key: pf_poolhashkey, + pub counter: pf_addr, + pub tblidx: ::std::os::raw::c_int, + pub proxy_port: [u_int16_t; 2usize], + pub port_op: u_int8_t, + pub opts: u_int8_t, + pub af: sa_family_t, +} +#[test] +fn bindgen_test_layout_pf_pool() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 72usize, + concat!("Size of: ", stringify!(pf_pool)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_pool)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).list) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(list)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cur) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(cur)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(key)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).counter) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(counter)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tblidx) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(tblidx)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proxy_port) as usize - ptr as usize }, + 60usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(proxy_port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port_op) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(port_op)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).opts) as usize - ptr as usize }, + 65usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 66usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(af)) + ); +} +pub type pf_osfp_t = u_int32_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_osfp_entry { + pub fp_entry: pf_osfp_entry__bindgen_ty_1, + pub fp_os: pf_osfp_t, + pub fp_enflags: ::std::os::raw::c_int, + pub fp_class_nm: [::std::os::raw::c_char; 32usize], + pub fp_version_nm: [::std::os::raw::c_char; 32usize], + pub fp_subtype_nm: [::std::os::raw::c_char; 32usize], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_osfp_entry__bindgen_ty_1 { + pub sle_next: *mut pf_osfp_entry, +} +#[test] +fn bindgen_test_layout_pf_osfp_entry__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_osfp_entry__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_osfp_entry__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_osfp_entry() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 112usize, + concat!("Size of: ", stringify!(pf_osfp_entry)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_osfp_entry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_entry) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_entry) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_os) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_osfp_entry), "::", stringify!(fp_os)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_enflags) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_enflags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_class_nm) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_class_nm) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_version_nm) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_version_nm) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_subtype_nm) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_subtype_nm) + ) + ); +} +pub type pf_tcpopts_t = u_int64_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_os_fingerprint { + pub fp_oses: pf_os_fingerprint_pf_osfp_enlist, + pub fp_tcpopts: pf_tcpopts_t, + pub fp_wsize: u_int16_t, + pub fp_psize: u_int16_t, + pub fp_mss: u_int16_t, + pub fp_flags: u_int16_t, + pub fp_optcnt: u_int8_t, + pub fp_wscale: u_int8_t, + pub fp_ttl: u_int8_t, + pub fp_next: pf_os_fingerprint__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_os_fingerprint_pf_osfp_enlist { + pub slh_first: *mut pf_osfp_entry, +} +#[test] +fn bindgen_test_layout_pf_os_fingerprint_pf_osfp_enlist() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_os_fingerprint_pf_osfp_enlist)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_os_fingerprint_pf_osfp_enlist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).slh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint_pf_osfp_enlist), + "::", + stringify!(slh_first) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_os_fingerprint__bindgen_ty_1 { + pub sle_next: *mut pf_os_fingerprint, +} +#[test] +fn bindgen_test_layout_pf_os_fingerprint__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_os_fingerprint__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_os_fingerprint__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_os_fingerprint() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pf_os_fingerprint)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_os_fingerprint)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_oses) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_oses) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_tcpopts) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_tcpopts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wsize) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_wsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_psize) as usize - ptr as usize }, + 18usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_psize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_mss) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_flags) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_optcnt) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_optcnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wscale) as usize - ptr as usize }, + 25usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_ttl) as usize - ptr as usize }, + 26usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_next) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_next) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_osfp_ioctl { + pub fp_os: pf_osfp_entry, + pub fp_tcpopts: pf_tcpopts_t, + pub fp_wsize: u_int16_t, + pub fp_psize: u_int16_t, + pub fp_mss: u_int16_t, + pub fp_flags: u_int16_t, + pub fp_optcnt: u_int8_t, + pub fp_wscale: u_int8_t, + pub fp_ttl: u_int8_t, + pub fp_getnum: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_osfp_ioctl() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 136usize, + concat!("Size of: ", stringify!(pf_osfp_ioctl)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_osfp_ioctl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_os) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_osfp_ioctl), "::", stringify!(fp_os)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_tcpopts) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_tcpopts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wsize) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_wsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_psize) as usize - ptr as usize }, + 122usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_psize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_mss) as usize - ptr as usize }, + 124usize, + concat!("Offset of field: ", stringify!(pf_osfp_ioctl), "::", stringify!(fp_mss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_flags) as usize - ptr as usize }, + 126usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_optcnt) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_optcnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wscale) as usize - ptr as usize }, + 129usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_ttl) as usize - ptr as usize }, + 130usize, + concat!("Offset of field: ", stringify!(pf_osfp_ioctl), "::", stringify!(fp_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_getnum) as usize - ptr as usize }, + 132usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_getnum) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_rule_ptr { + pub ptr: *mut pf_rule, + pub nr: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_rule_ptr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_rule_ptr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule_ptr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_ptr), "::", stringify!(ptr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_ptr), "::", stringify!(nr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_rule { + pub src: pf_rule_addr, + pub dst: pf_rule_addr, + pub skip: [pf_rule_ptr; 8usize], + pub label: [::std::os::raw::c_char; 64usize], + pub ifname: [::std::os::raw::c_char; 16usize], + pub qname: [::std::os::raw::c_char; 64usize], + pub pqname: [::std::os::raw::c_char; 64usize], + pub tagname: [::std::os::raw::c_char; 64usize], + pub match_tagname: [::std::os::raw::c_char; 64usize], + pub overload_tblname: [::std::os::raw::c_char; 32usize], + pub entries: pf_rule__bindgen_ty_1, + pub rpool: pf_pool, + pub evaluations: u_int64_t, + pub packets: [u_int64_t; 2usize], + pub bytes: [u_int64_t; 2usize], + pub ticket: u_int64_t, + pub owner: [::std::os::raw::c_char; 64usize], + pub priority: u_int32_t, + pub kif: *mut ::std::os::raw::c_void, + pub anchor: *mut pf_anchor, + pub overload_tbl: *mut ::std::os::raw::c_void, + pub os_fingerprint: pf_osfp_t, + pub rtableid: ::std::os::raw::c_uint, + pub timeout: [u_int32_t; 26usize], + pub states: u_int32_t, + pub max_states: u_int32_t, + pub src_nodes: u_int32_t, + pub max_src_nodes: u_int32_t, + pub max_src_states: u_int32_t, + pub max_src_conn: u_int32_t, + pub max_src_conn_rate: pf_rule__bindgen_ty_2, + pub qid: u_int32_t, + pub pqid: u_int32_t, + pub rt_listid: u_int32_t, + pub nr: u_int32_t, + pub prob: u_int32_t, + pub cuid: uid_t, + pub cpid: pid_t, + pub return_icmp: u_int16_t, + pub return_icmp6: u_int16_t, + pub max_mss: u_int16_t, + pub tag: u_int16_t, + pub match_tag: u_int16_t, + pub uid: pf_rule_uid, + pub gid: pf_rule_gid, + pub rule_flag: u_int32_t, + pub action: u_int8_t, + pub direction: u_int8_t, + pub log: u_int8_t, + pub logif: u_int8_t, + pub quick: u_int8_t, + pub ifnot: u_int8_t, + pub match_tag_not: u_int8_t, + pub natpass: u_int8_t, + pub keep_state: u_int8_t, + pub af: sa_family_t, + pub proto: u_int8_t, + pub type_: u_int8_t, + pub code: u_int8_t, + pub flags: u_int8_t, + pub flagset: u_int8_t, + pub min_ttl: u_int8_t, + pub allow_opts: u_int8_t, + pub rt: u_int8_t, + pub return_ttl: u_int8_t, + pub tos: u_int8_t, + pub anchor_relative: u_int8_t, + pub anchor_wildcard: u_int8_t, + pub flush: u_int8_t, + pub proto_variant: u_int8_t, + pub extfilter: u_int8_t, + pub extmap: u_int8_t, + pub dnpipe: u_int32_t, + pub dntype: u_int32_t, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule__bindgen_ty_1 { + pub tqe_next: *mut pf_rule, + pub tqe_prev: *mut *mut pf_rule, +} +#[test] +fn bindgen_test_layout_pf_rule__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_rule__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule__bindgen_ty_2 { + pub limit: u_int32_t, + pub seconds: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_rule__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_rule__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_2), + "::", + stringify!(limit) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seconds) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_2), + "::", + stringify!(seconds) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_rule() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1040usize, + concat!("Size of: ", stringify!(pf_rule)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(src)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dst) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(dst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).skip) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(skip)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).label) as usize - ptr as usize }, + 192usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(label)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 256usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qname) as usize - ptr as usize }, + 272usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(qname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pqname) as usize - ptr as usize }, + 336usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(pqname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tagname) as usize - ptr as usize }, + 400usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(tagname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_tagname) as usize - ptr as usize }, + 464usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(match_tagname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).overload_tblname) as usize - ptr as usize }, + 528usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(overload_tblname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 560usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rpool) as usize - ptr as usize }, + 576usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rpool)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).evaluations) as usize - ptr as usize }, + 648usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(evaluations)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 656usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 672usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 688usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).owner) as usize - ptr as usize }, + 696usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(owner)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).priority) as usize - ptr as usize }, + 760usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(priority)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 768usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 776usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).overload_tbl) as usize - ptr as usize }, + 784usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(overload_tbl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).os_fingerprint) as usize - ptr as usize }, + 792usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(os_fingerprint) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtableid) as usize - ptr as usize }, + 796usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rtableid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 800usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(timeout)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 904usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_states) as usize - ptr as usize }, + 908usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(max_states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src_nodes) as usize - ptr as usize }, + 912usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(src_nodes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_nodes) as usize - ptr as usize }, + 916usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(max_src_nodes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_states) as usize - ptr as usize }, + 920usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(max_src_states) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_conn) as usize - ptr as usize }, + 924usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(max_src_conn)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_conn_rate) as usize - ptr as usize }, + 928usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(max_src_conn_rate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 936usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(qid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pqid) as usize - ptr as usize }, + 940usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(pqid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_listid) as usize - ptr as usize }, + 944usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rt_listid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 948usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).prob) as usize - ptr as usize }, + 952usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(prob)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cuid) as usize - ptr as usize }, + 956usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(cuid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cpid) as usize - ptr as usize }, + 960usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(cpid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).return_icmp) as usize - ptr as usize }, + 964usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(return_icmp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).return_icmp6) as usize - ptr as usize }, + 966usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(return_icmp6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_mss) as usize - ptr as usize }, + 968usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(max_mss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tag) as usize - ptr as usize }, + 970usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_tag) as usize - ptr as usize }, + 972usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(match_tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uid) as usize - ptr as usize }, + 976usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gid) as usize - ptr as usize }, + 988usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule_flag) as usize - ptr as usize }, + 1000usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rule_flag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 1004usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(action)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 1005usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(direction)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).log) as usize - ptr as usize }, + 1006usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(log)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).logif) as usize - ptr as usize }, + 1007usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(logif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).quick) as usize - ptr as usize }, + 1008usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(quick)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnot) as usize - ptr as usize }, + 1009usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(ifnot)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_tag_not) as usize - ptr as usize }, + 1010usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(match_tag_not) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).natpass) as usize - ptr as usize }, + 1011usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(natpass)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).keep_state) as usize - ptr as usize }, + 1012usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(keep_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 1013usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 1014usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(proto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 1015usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(type_)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).code) as usize - ptr as usize }, + 1016usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(code)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 1017usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flagset) as usize - ptr as usize }, + 1018usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(flagset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).min_ttl) as usize - ptr as usize }, + 1019usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(min_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).allow_opts) as usize - ptr as usize }, + 1020usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(allow_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt) as usize - ptr as usize }, + 1021usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).return_ttl) as usize - ptr as usize }, + 1022usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(return_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos) as usize - ptr as usize }, + 1023usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(tos)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor_relative) as usize - ptr as usize }, + 1024usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(anchor_relative) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor_wildcard) as usize - ptr as usize }, + 1025usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(anchor_wildcard) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flush) as usize - ptr as usize }, + 1026usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(flush)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto_variant) as usize - ptr as usize }, + 1027usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(proto_variant) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).extfilter) as usize - ptr as usize }, + 1028usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(extfilter)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).extmap) as usize - ptr as usize }, + 1029usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(extmap)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dnpipe) as usize - ptr as usize }, + 1032usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(dnpipe)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dntype) as usize - ptr as usize }, + 1036usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(dntype)) + ); +} +pub const pf_extmap_PF_EXTMAP_APD: pf_extmap = 1; +pub const pf_extmap_PF_EXTMAP_AD: pf_extmap = 2; +pub const pf_extmap_PF_EXTMAP_EI: pf_extmap = 3; +pub type pf_extmap = ::std::os::raw::c_uint; +pub const pf_extfilter_PF_EXTFILTER_APD: pf_extfilter = 1; +pub const pf_extfilter_PF_EXTFILTER_AD: pf_extfilter = 2; +pub const pf_extfilter_PF_EXTFILTER_EI: pf_extfilter = 3; +pub type pf_extfilter = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_threshold { + pub limit: u_int32_t, + pub seconds: u_int32_t, + pub count: u_int32_t, + pub last: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_threshold() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_threshold)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_threshold)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(limit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seconds) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(seconds)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).count) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(count)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).last) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(last)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_src_node { + pub entry: pf_src_node__bindgen_ty_1, + pub addr: pf_addr, + pub raddr: pf_addr, + pub rule: pf_rule_ptr, + pub kif: *mut ::std::os::raw::c_void, + pub bytes: [u_int64_t; 2usize], + pub packets: [u_int64_t; 2usize], + pub states: u_int32_t, + pub conn: u_int32_t, + pub conn_rate: pf_threshold, + pub creation: u_int64_t, + pub expire: u_int64_t, + pub af: sa_family_t, + pub ruletype: u_int8_t, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_src_node__bindgen_ty_1 { + pub rbe_left: *mut pf_src_node, + pub rbe_right: *mut pf_src_node, + pub rbe_parent: *mut pf_src_node, +} +#[test] +fn bindgen_test_layout_pf_src_node__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_src_node__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_src_node__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_left) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node__bindgen_ty_1), + "::", + stringify!(rbe_left) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_right) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node__bindgen_ty_1), + "::", + stringify!(rbe_right) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_parent) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node__bindgen_ty_1), + "::", + stringify!(rbe_parent) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_src_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 152usize, + concat!("Size of: ", stringify!(pf_src_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_src_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(entry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).raddr) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(raddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 88usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 104usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).conn) as usize - ptr as usize }, + 108usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(conn)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).conn_rate) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node), + "::", + stringify!(conn_rate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creation) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(creation)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).expire) as usize - ptr as usize }, + 136usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(expire)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 144usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ruletype) as usize - ptr as usize }, + 145usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(ruletype)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_state_xport { + pub port: u_int16_t, + pub call_id: u_int16_t, + pub spi: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_state_xport() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pf_state_xport)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_state_xport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_xport), "::", stringify!(port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).call_id) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_xport), + "::", + stringify!(call_id) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).spi) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_xport), "::", stringify!(spi)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_state_host { + pub addr: pf_addr, + pub xport: pf_state_xport, +} +#[test] +fn bindgen_test_layout_pf_state_host() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pf_state_host)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_state_host)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_host), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).xport) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_state_host), "::", stringify!(xport)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct hook_desc { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct hook_desc_head { + pub tqh_first: *mut hook_desc, + pub tqh_last: *mut *mut hook_desc, +} +#[test] +fn bindgen_test_layout_hook_desc_head() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(hook_desc_head)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(hook_desc_head)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(hook_desc_head), + "::", + stringify!(tqh_first) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(hook_desc_head), + "::", + stringify!(tqh_last) + ) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct pfsync_state_scrub { + pub pfss_flags: u_int16_t, + pub pfss_ttl: u_int8_t, + pub scrub_flag: u_int8_t, + pub pfss_ts_mod: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfsync_state_scrub() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfsync_state_scrub)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_scrub)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_flags) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(pfss_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ttl) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(pfss_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub_flag) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(scrub_flag) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ts_mod) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(pfss_ts_mod) + ) + ); +} +#[repr(C, packed)] +#[derive(Copy, Clone)] +pub struct pfsync_state_host { + pub addr: pf_addr, + pub xport: pf_state_xport, + pub pad: [u_int16_t; 2usize], +} +#[test] +fn bindgen_test_layout_pfsync_state_host() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pfsync_state_host)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_host)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_host), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).xport) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_host), + "::", + stringify!(xport) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_host), + "::", + stringify!(pad) + ) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct pfsync_state_peer { + pub scrub: pfsync_state_scrub, + pub seqlo: u_int32_t, + pub seqhi: u_int32_t, + pub seqdiff: u_int32_t, + pub max_win: u_int16_t, + pub mss: u_int16_t, + pub state: u_int8_t, + pub wscale: u_int8_t, + pub pad: [u_int8_t; 6usize], +} +#[test] +fn bindgen_test_layout_pfsync_state_peer() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pfsync_state_peer)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_peer)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(scrub) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqlo) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(seqlo) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqhi) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(seqhi) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqdiff) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(seqdiff) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_win) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(max_win) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mss) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(state) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).wscale) as usize - ptr as usize }, + 25usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 26usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(pad) + ) + ); +} +#[repr(C, packed)] +#[derive(Copy, Clone)] +pub struct pfsync_state { + pub id: [u_int32_t; 2usize], + pub ifname: [::std::os::raw::c_char; 16usize], + pub lan: pfsync_state_host, + pub gwy: pfsync_state_host, + pub ext_lan: pfsync_state_host, + pub ext_gwy: pfsync_state_host, + pub src: pfsync_state_peer, + pub dst: pfsync_state_peer, + pub rt_addr: pf_addr, + pub unlink_hooks: hook_desc_head, + pub rule: u_int32_t, + pub anchor: u_int32_t, + pub nat_rule: u_int32_t, + pub creation: u_int64_t, + pub expire: u_int64_t, + pub packets: [[u_int32_t; 2usize]; 2usize], + pub bytes: [[u_int32_t; 2usize]; 2usize], + pub creatorid: u_int32_t, + pub tag: u_int16_t, + pub af_lan: sa_family_t, + pub af_gwy: sa_family_t, + pub proto: u_int8_t, + pub direction: u_int8_t, + pub log: u_int8_t, + pub allow_opts: u_int8_t, + pub timeout: u_int8_t, + pub sync_flags: u_int8_t, + pub updates: u_int8_t, + pub proto_variant: u_int8_t, + pub __pad: u_int8_t, + pub flowhash: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfsync_state() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 297usize, + concat!("Size of: ", stringify!(pfsync_state)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).id) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(id)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lan) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(lan)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gwy) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(gwy)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ext_lan) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(ext_lan)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ext_gwy) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(ext_gwy)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src) as usize - ptr as usize }, + 120usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(src)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dst) as usize - ptr as usize }, + 152usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(dst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_addr) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(rt_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).unlink_hooks) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(unlink_hooks) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 216usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 220usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nat_rule) as usize - ptr as usize }, + 224usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(nat_rule) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creation) as usize - ptr as usize }, + 228usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(creation) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).expire) as usize - ptr as usize }, + 236usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(expire)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 244usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 260usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creatorid) as usize - ptr as usize }, + 276usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(creatorid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tag) as usize - ptr as usize }, + 280usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af_lan) as usize - ptr as usize }, + 282usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(af_lan)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af_gwy) as usize - ptr as usize }, + 283usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(af_gwy)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 284usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(proto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 285usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(direction) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).log) as usize - ptr as usize }, + 286usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(log)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).allow_opts) as usize - ptr as usize }, + 287usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(allow_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 288usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(timeout)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sync_flags) as usize - ptr as usize }, + 289usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(sync_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).updates) as usize - ptr as usize }, + 290usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(updates)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto_variant) as usize - ptr as usize }, + 291usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(proto_variant) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__pad) as usize - ptr as usize }, + 292usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(__pad)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flowhash) as usize - ptr as usize }, + 293usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(flowhash) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rulequeue { + pub tqh_first: *mut pf_rule, + pub tqh_last: *mut *mut pf_rule, +} +#[test] +fn bindgen_test_layout_pf_rulequeue() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_rulequeue)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rulequeue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rulequeue), + "::", + stringify!(tqh_first) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_rulequeue), + "::", + stringify!(tqh_last) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ruleset { + pub rules: [pf_ruleset__bindgen_ty_1; 6usize], + pub anchor: *mut pf_anchor, + pub tticket: u_int32_t, + pub tables: ::std::os::raw::c_int, + pub topen: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ruleset__bindgen_ty_1 { + pub queues: [pf_rulequeue; 2usize], + pub active: pf_ruleset__bindgen_ty_1__bindgen_ty_1, + pub inactive: pf_ruleset__bindgen_ty_1__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ruleset__bindgen_ty_1__bindgen_ty_1 { + pub ptr: *mut pf_rulequeue, + pub ptr_array: *mut *mut pf_rule, + pub rcount: u_int32_t, + pub ticket: u_int32_t, + pub open: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_ruleset__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ptr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr_array) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ptr_array) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rcount) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rcount) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ticket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).open) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(open) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_ruleset__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(pf_ruleset__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ruleset__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).queues) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1), + "::", + stringify!(queues) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).active) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1), + "::", + stringify!(active) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).inactive) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1), + "::", + stringify!(inactive) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_ruleset() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 600usize, + concat!("Size of: ", stringify!(pf_ruleset)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rules) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(rules)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 576usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tticket) as usize - ptr as usize }, + 584usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(tticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tables) as usize - ptr as usize }, + 588usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(tables)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).topen) as usize - ptr as usize }, + 592usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(topen)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor_global { + pub rbh_root: *mut pf_anchor, +} +#[test] +fn bindgen_test_layout_pf_anchor_global() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_anchor_global)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor_global)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor_global), + "::", + stringify!(rbh_root) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor_node { + pub rbh_root: *mut pf_anchor, +} +#[test] +fn bindgen_test_layout_pf_anchor_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_anchor_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor_node), + "::", + stringify!(rbh_root) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor { + pub entry_global: pf_anchor__bindgen_ty_1, + pub entry_node: pf_anchor__bindgen_ty_2, + pub parent: *mut pf_anchor, + pub children: pf_anchor_node, + pub name: [::std::os::raw::c_char; 64usize], + pub path: [::std::os::raw::c_char; 1024usize], + pub ruleset: pf_ruleset, + pub refcnt: ::std::os::raw::c_int, + pub match_: ::std::os::raw::c_int, + pub owner: [::std::os::raw::c_char; 64usize], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor__bindgen_ty_1 { + pub rbe_left: *mut pf_anchor, + pub rbe_right: *mut pf_anchor, + pub rbe_parent: *mut pf_anchor, +} +#[test] +fn bindgen_test_layout_pf_anchor__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_anchor__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_left) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_1), + "::", + stringify!(rbe_left) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_right) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_1), + "::", + stringify!(rbe_right) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_parent) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_1), + "::", + stringify!(rbe_parent) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor__bindgen_ty_2 { + pub rbe_left: *mut pf_anchor, + pub rbe_right: *mut pf_anchor, + pub rbe_parent: *mut pf_anchor, +} +#[test] +fn bindgen_test_layout_pf_anchor__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_anchor__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_left) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_2), + "::", + stringify!(rbe_left) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_right) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_2), + "::", + stringify!(rbe_right) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_parent) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_2), + "::", + stringify!(rbe_parent) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_anchor() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1824usize, + concat!("Size of: ", stringify!(pf_anchor)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry_global) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor), + "::", + stringify!(entry_global) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry_node) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(entry_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).children) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(children)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).path) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(path)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ruleset) as usize - ptr as usize }, + 1152usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).refcnt) as usize - ptr as usize }, + 1752usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(refcnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_) as usize - ptr as usize }, + 1756usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(match_)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).owner) as usize - ptr as usize }, + 1760usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(owner)) + ); +} +extern "C" { + pub fn pf_anchor_global_RB_INSERT_COLOR(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor); +} +extern "C" { + pub fn pf_anchor_global_RB_REMOVE_COLOR(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor, arg3: *mut pf_anchor); +} +extern "C" { + pub fn pf_anchor_global_RB_REMOVE(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_INSERT(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_FIND(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_NFIND(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_NEXT(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_MINMAX(arg1: *mut pf_anchor_global, arg2: ::std::os::raw::c_int) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_GETPARENT(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_SETPARENT(arg1: *mut pf_anchor, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_GETCOLOR(arg1: *mut pf_anchor) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_anchor_global_RB_SETCOLOR(arg1: *mut pf_anchor, arg2: ::std::os::raw::c_int); +} +extern "C" { + pub fn pf_anchor_node_RB_INSERT_COLOR(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor); +} +extern "C" { + pub fn pf_anchor_node_RB_REMOVE_COLOR(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor, arg3: *mut pf_anchor); +} +extern "C" { + pub fn pf_anchor_node_RB_REMOVE(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_INSERT(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_FIND(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_NFIND(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_NEXT(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_MINMAX(arg1: *mut pf_anchor_node, arg2: ::std::os::raw::c_int) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_GETPARENT(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_SETPARENT(arg1: *mut pf_anchor, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_GETCOLOR(arg1: *mut pf_anchor) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_anchor_node_RB_SETCOLOR(arg1: *mut pf_anchor, arg2: ::std::os::raw::c_int); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_table { + pub pfrt_anchor: [::std::os::raw::c_char; 1024usize], + pub pfrt_name: [::std::os::raw::c_char; 32usize], + pub pfrt_flags: u32, + pub pfrt_fback: u8, +} +#[test] +fn bindgen_test_layout_pfr_table() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1064usize, + concat!("Size of: ", stringify!(pfr_table)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfr_table)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_anchor) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_table), + "::", + stringify!(pfrt_anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_name) as usize - ptr as usize }, + 1024usize, + concat!("Offset of field: ", stringify!(pfr_table), "::", stringify!(pfrt_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_flags) as usize - ptr as usize }, + 1056usize, + concat!("Offset of field: ", stringify!(pfr_table), "::", stringify!(pfrt_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_fback) as usize - ptr as usize }, + 1060usize, + concat!("Offset of field: ", stringify!(pfr_table), "::", stringify!(pfrt_fback)) + ); +} +pub const PFR_FB_NONE: _bindgen_ty_13 = 0; +pub const PFR_FB_MATCH: _bindgen_ty_13 = 1; +pub const PFR_FB_ADDED: _bindgen_ty_13 = 2; +pub const PFR_FB_DELETED: _bindgen_ty_13 = 3; +pub const PFR_FB_CHANGED: _bindgen_ty_13 = 4; +pub const PFR_FB_CLEARED: _bindgen_ty_13 = 5; +pub const PFR_FB_DUPLICATE: _bindgen_ty_13 = 6; +pub const PFR_FB_NOTMATCH: _bindgen_ty_13 = 7; +pub const PFR_FB_CONFLICT: _bindgen_ty_13 = 8; +pub const PFR_FB_MAX: _bindgen_ty_13 = 9; +pub type _bindgen_ty_13 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_addr { + pub pfra_u: pfr_addr__bindgen_ty_1, + pub pfra_af: u8, + pub pfra_net: u8, + pub pfra_not: u8, + pub pfra_fback: u8, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfr_addr__bindgen_ty_1 { + pub _pfra_ip4addr: in_addr, + pub _pfra_ip6addr: in6_addr, +} +#[test] +fn bindgen_test_layout_pfr_addr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfr_addr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfr_addr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfra_ip4addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_addr__bindgen_ty_1), + "::", + stringify!(_pfra_ip4addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfra_ip6addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_addr__bindgen_ty_1), + "::", + stringify!(_pfra_ip6addr) + ) + ); +} +#[test] +fn bindgen_test_layout_pfr_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pfr_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfr_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_u) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_u)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_af) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_net) as usize - ptr as usize }, + 17usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_net)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_not) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_not)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_fback) as usize - ptr as usize }, + 19usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_fback)) + ); +} +pub const PFR_DIR_IN: _bindgen_ty_14 = 0; +pub const PFR_DIR_OUT: _bindgen_ty_14 = 1; +pub const PFR_DIR_MAX: _bindgen_ty_14 = 2; +pub type _bindgen_ty_14 = ::std::os::raw::c_uint; +pub const PFR_OP_BLOCK: _bindgen_ty_15 = 0; +pub const PFR_OP_PASS: _bindgen_ty_15 = 1; +pub const PFR_OP_ADDR_MAX: _bindgen_ty_15 = 2; +pub const PFR_OP_TABLE_MAX: _bindgen_ty_15 = 3; +pub type _bindgen_ty_15 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_astats { + pub pfras_a: pfr_addr, + pub pfras_packets: [[u64; 2usize]; 2usize], + pub pfras_bytes: [[u64; 2usize]; 2usize], + pub pfras_tzero: u64, +} +#[test] +fn bindgen_test_layout_pfr_astats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(pfr_astats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_astats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_a) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_astats), "::", stringify!(pfras_a)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_packets) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfr_astats), + "::", + stringify!(pfras_packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_bytes) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(pfr_astats), + "::", + stringify!(pfras_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_tzero) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(pfr_astats), + "::", + stringify!(pfras_tzero) + ) + ); +} +pub const PFR_REFCNT_RULE: _bindgen_ty_16 = 0; +pub const PFR_REFCNT_ANCHOR: _bindgen_ty_16 = 1; +pub const PFR_REFCNT_MAX: _bindgen_ty_16 = 2; +pub type _bindgen_ty_16 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_tstats { + pub pfrts_t: pfr_table, + pub pfrts_packets: [[u_int64_t; 3usize]; 2usize], + pub pfrts_bytes: [[u_int64_t; 3usize]; 2usize], + pub pfrts_match: u_int64_t, + pub pfrts_nomatch: u_int64_t, + pub pfrts_tzero: u_int64_t, + pub pfrts_cnt: ::std::os::raw::c_int, + pub pfrts_refcnt: [::std::os::raw::c_int; 2usize], +} +#[test] +fn bindgen_test_layout_pfr_tstats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1200usize, + concat!("Size of: ", stringify!(pfr_tstats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_tstats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_t) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_tstats), "::", stringify!(pfrts_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_packets) as usize - ptr as usize }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_bytes) as usize - ptr as usize }, + 1112usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_match) as usize - ptr as usize }, + 1160usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_match) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_nomatch) as usize - ptr as usize }, + 1168usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_nomatch) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_tzero) as usize - ptr as usize }, + 1176usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_tzero) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_cnt) as usize - ptr as usize }, + 1184usize, + concat!("Offset of field: ", stringify!(pfr_tstats), "::", stringify!(pfrts_cnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_refcnt) as usize - ptr as usize }, + 1188usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_refcnt) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_kif { + pub pfik_name: [::std::os::raw::c_char; 16usize], + pub pfik_packets: [[[u_int64_t; 2usize]; 2usize]; 2usize], + pub pfik_bytes: [[[u_int64_t; 2usize]; 2usize]; 2usize], + pub pfik_tzero: u_int64_t, + pub pfik_flags: ::std::os::raw::c_int, + pub pfik_states: ::std::os::raw::c_int, + pub pfik_rules: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfi_kif() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 168usize, + concat!("Size of: ", stringify!(pfi_kif)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_packets) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_bytes) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_tzero) as usize - ptr as usize }, + 144usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_tzero)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_flags) as usize - ptr as usize }, + 152usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_states) as usize - ptr as usize }, + 156usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_rules) as usize - ptr as usize }, + 160usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_rules)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_status { + pub counters: [u_int64_t; 16usize], + pub lcounters: [u_int64_t; 7usize], + pub fcounters: [u_int64_t; 3usize], + pub scounters: [u_int64_t; 3usize], + pub pcounters: [[[u_int64_t; 3usize]; 2usize]; 2usize], + pub bcounters: [[u_int64_t; 2usize]; 2usize], + pub stateid: u_int64_t, + pub running: u_int32_t, + pub states: u_int32_t, + pub src_nodes: u_int32_t, + pub since: u_int64_t, + pub debug: u_int32_t, + pub hostid: u_int32_t, + pub ifname: [::std::os::raw::c_char; 16usize], + pub pf_chksum: [u_int8_t; 16usize], +} +#[test] +fn bindgen_test_layout_pf_status() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 432usize, + concat!("Size of: ", stringify!(pf_status)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_status)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).counters) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(counters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lcounters) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(lcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fcounters) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(fcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scounters) as usize - ptr as usize }, + 208usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(scounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pcounters) as usize - ptr as usize }, + 232usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(pcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bcounters) as usize - ptr as usize }, + 328usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(bcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).stateid) as usize - ptr as usize }, + 360usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(stateid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).running) as usize - ptr as usize }, + 368usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(running)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 372usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src_nodes) as usize - ptr as usize }, + 376usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(src_nodes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).since) as usize - ptr as usize }, + 384usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(since)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).debug) as usize - ptr as usize }, + 392usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(debug)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hostid) as usize - ptr as usize }, + 396usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(hostid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 400usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pf_chksum) as usize - ptr as usize }, + 416usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(pf_chksum)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct cbq_opts { + pub minburst: u_int32_t, + pub maxburst: u_int32_t, + pub pktsize: u_int32_t, + pub maxpktsize: u_int32_t, + pub ns_per_byte: u_int32_t, + pub maxidle: u_int32_t, + pub minidle: i32, + pub offtime: u_int32_t, + pub flags: u_int32_t, +} +#[test] +fn bindgen_test_layout_cbq_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 36usize, + concat!("Size of: ", stringify!(cbq_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(cbq_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).minburst) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(minburst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).maxburst) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(maxburst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pktsize) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(pktsize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).maxpktsize) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(maxpktsize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ns_per_byte) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(ns_per_byte)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).maxidle) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(maxidle)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).minidle) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(minidle)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).offtime) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(offtime)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(cbq_opts), "::", stringify!(flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct priq_opts { + pub flags: u_int32_t, +} +#[test] +fn bindgen_test_layout_priq_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(priq_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(priq_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(priq_opts), "::", stringify!(flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct hfsc_opts { + pub rtsc_m1: u_int64_t, + pub rtsc_d: u_int64_t, + pub rtsc_m2: u_int64_t, + pub rtsc_fl: u_int32_t, + pub lssc_m1: u_int64_t, + pub lssc_d: u_int64_t, + pub lssc_m2: u_int64_t, + pub lssc_fl: u_int32_t, + pub ulsc_m1: u_int64_t, + pub ulsc_d: u_int64_t, + pub ulsc_m2: u_int64_t, + pub ulsc_fl: u_int32_t, + pub flags: u_int32_t, +} +#[test] +fn bindgen_test_layout_hfsc_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(hfsc_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(hfsc_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_m1) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(rtsc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_d) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(rtsc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_m2) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(rtsc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_fl) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(rtsc_fl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m1) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(lssc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_d) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(lssc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m2) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(lssc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_fl) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(lssc_fl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_m1) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(ulsc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_d) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(ulsc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_m2) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(ulsc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_fl) as usize - ptr as usize }, + 88usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(ulsc_fl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 92usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct fairq_opts { + pub nbuckets: u_int32_t, + pub flags: u_int32_t, + pub hogs_m1: u_int64_t, + pub lssc_m1: u_int64_t, + pub lssc_d: u_int64_t, + pub lssc_m2: u_int64_t, +} +#[test] +fn bindgen_test_layout_fairq_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(fairq_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(fairq_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nbuckets) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(nbuckets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hogs_m1) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(hogs_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m1) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(lssc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_d) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(lssc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m2) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(fairq_opts), "::", stringify!(lssc_m2)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_altq { + pub ifname: [::std::os::raw::c_char; 16usize], + pub altq_disc: *mut ::std::os::raw::c_void, + pub entries: pf_altq__bindgen_ty_1, + pub aflags: u_int32_t, + pub bwtype: u_int32_t, + pub scheduler: u_int32_t, + pub tbrsize: u_int32_t, + pub ifbandwidth: u_int64_t, + pub qname: [::std::os::raw::c_char; 64usize], + pub parent: [::std::os::raw::c_char; 64usize], + pub parent_qid: u_int32_t, + pub qrflags: u_int32_t, + pub __bindgen_anon_1: pf_altq__bindgen_ty_2, + pub qlimit: u_int32_t, + pub flags: u_int32_t, + pub bandwidth: u_int64_t, + pub pq_u: pf_altq__bindgen_ty_3, + pub qid: u_int32_t, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_altq__bindgen_ty_1 { + pub tqe_next: *mut pf_altq, + pub tqe_prev: *mut *mut pf_altq, +} +#[test] +fn bindgen_test_layout_pf_altq__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_altq__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_altq__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_altq__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_altq__bindgen_ty_2 { + pub priority: u_int32_t, + pub weight: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_altq__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pf_altq__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_altq__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).priority) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq__bindgen_ty_2), + "::", + stringify!(priority) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).weight) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq__bindgen_ty_2), + "::", + stringify!(weight) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_altq__bindgen_ty_3 { + pub cbq_opts: cbq_opts, + pub priq_opts: priq_opts, + pub hfsc_opts: hfsc_opts, + pub fairq_opts: fairq_opts, +} +#[test] +fn bindgen_test_layout_pf_altq__bindgen_ty_3() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(pf_altq__bindgen_ty_3)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_altq__bindgen_ty_3)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cbq_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq__bindgen_ty_3), + "::", + stringify!(cbq_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).priq_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq__bindgen_ty_3), + "::", + stringify!(priq_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hfsc_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq__bindgen_ty_3), + "::", + stringify!(hfsc_opts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fairq_opts) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_altq__bindgen_ty_3), + "::", + stringify!(fairq_opts) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_altq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 328usize, + concat!("Size of: ", stringify!(pf_altq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_altq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).altq_disc) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(altq_disc)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).aflags) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(aflags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bwtype) as usize - ptr as usize }, + 44usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(bwtype)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scheduler) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(scheduler)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tbrsize) as usize - ptr as usize }, + 52usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(tbrsize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifbandwidth) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(ifbandwidth)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qname) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(qname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent) as usize - ptr as usize }, + 128usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent_qid) as usize - ptr as usize }, + 192usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(parent_qid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qrflags) as usize - ptr as usize }, + 196usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(qrflags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qlimit) as usize - ptr as usize }, + 204usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(qlimit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 208usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bandwidth) as usize - ptr as usize }, + 216usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(bandwidth)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pq_u) as usize - ptr as usize }, + 224usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(pq_u)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 320usize, + concat!("Offset of field: ", stringify!(pf_altq), "::", stringify!(qid)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_tagname { + pub entries: pf_tagname__bindgen_ty_1, + pub name: [::std::os::raw::c_char; 64usize], + pub tag: u_int16_t, + pub ref_: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_tagname__bindgen_ty_1 { + pub tqe_next: *mut pf_tagname, + pub tqe_prev: *mut *mut pf_tagname, +} +#[test] +fn bindgen_test_layout_pf_tagname__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_tagname__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_tagname__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_tagname__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_tagname__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_tagname() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 88usize, + concat!("Size of: ", stringify!(pf_tagname)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_tagname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_tagname), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_tagname), "::", stringify!(name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tag) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_tagname), "::", stringify!(tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ref_) as usize - ptr as usize }, + 84usize, + concat!("Offset of field: ", stringify!(pf_tagname), "::", stringify!(ref_)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_pooladdr { + pub action: u_int32_t, + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub r_num: u_int32_t, + pub r_action: u_int8_t, + pub r_last: u_int8_t, + pub af: u_int8_t, + pub anchor: [::std::os::raw::c_char; 1024usize], + pub addr: pf_pooladdr, +} +#[test] +fn bindgen_test_layout_pfioc_pooladdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1136usize, + concat!("Size of: ", stringify!(pfioc_pooladdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_pooladdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(action) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(ticket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_pooladdr), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).r_num) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pfioc_pooladdr), "::", stringify!(r_num)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).r_action) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(r_action) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).r_last) as usize - ptr as usize }, + 17usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(r_last) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(pfioc_pooladdr), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 19usize, + concat!( + "Offset of field: ", + stringify!(pfioc_pooladdr), + "::", + stringify!(anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 1048usize, + concat!("Offset of field: ", stringify!(pfioc_pooladdr), "::", stringify!(addr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_rule { + pub action: u_int32_t, + pub ticket: u_int32_t, + pub pool_ticket: u_int32_t, + pub nr: u_int32_t, + pub anchor: [::std::os::raw::c_char; 1024usize], + pub anchor_call: [::std::os::raw::c_char; 1024usize], + pub rule: pf_rule, +} +#[test] +fn bindgen_test_layout_pfioc_rule() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 3104usize, + concat!("Size of: ", stringify!(pfioc_rule)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(action)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pool_ticket) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_rule), + "::", + stringify!(pool_ticket) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor_call) as usize - ptr as usize }, + 1040usize, + concat!( + "Offset of field: ", + stringify!(pfioc_rule), + "::", + stringify!(anchor_call) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 2064usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(rule)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_natlook { + pub saddr: pf_addr, + pub daddr: pf_addr, + pub rsaddr: pf_addr, + pub rdaddr: pf_addr, + pub sxport: pf_state_xport, + pub dxport: pf_state_xport, + pub rsxport: pf_state_xport, + pub rdxport: pf_state_xport, + pub af: sa_family_t, + pub proto: u_int8_t, + pub proto_variant: u_int8_t, + pub direction: u_int8_t, +} +#[test] +fn bindgen_test_layout_pfioc_natlook() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 84usize, + concat!("Size of: ", stringify!(pfioc_natlook)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_natlook)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).saddr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(saddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).daddr) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(daddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rsaddr) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rsaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdaddr) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rdaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sxport) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(sxport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dxport) as usize - ptr as usize }, + 68usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(dxport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rsxport) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(pfioc_natlook), + "::", + stringify!(rsxport) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdxport) as usize - ptr as usize }, + 76usize, + concat!( + "Offset of field: ", + stringify!(pfioc_natlook), + "::", + stringify!(rdxport) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 81usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(proto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto_variant) as usize - ptr as usize }, + 82usize, + concat!( + "Offset of field: ", + stringify!(pfioc_natlook), + "::", + stringify!(proto_variant) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 83usize, + concat!( + "Offset of field: ", + stringify!(pfioc_natlook), + "::", + stringify!(direction) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_state { + pub state: pfsync_state, +} +#[test] +fn bindgen_test_layout_pfioc_state() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 297usize, + concat!("Size of: ", stringify!(pfioc_state)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfioc_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_state), "::", stringify!(state)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_src_node_kill { + pub psnk_af: sa_family_t, + pub psnk_src: pf_rule_addr, + pub psnk_dst: pf_rule_addr, +} +#[test] +fn bindgen_test_layout_pfioc_src_node_kill() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 136usize, + concat!("Size of: ", stringify!(pfioc_src_node_kill)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_src_node_kill)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_af) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_af) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_src) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_src) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_dst) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_dst) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_state_addr_kill { + pub addr: pf_addr_wrap, + pub reserved_: [u_int8_t; 3usize], + pub neg: u_int8_t, + pub xport: pf_rule_xport, +} +#[test] +fn bindgen_test_layout_pfioc_state_addr_kill() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(pfioc_state_addr_kill)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_state_addr_kill)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_addr_kill), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reserved_) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_addr_kill), + "::", + stringify!(reserved_) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).neg) as usize - ptr as usize }, + 51usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_addr_kill), + "::", + stringify!(neg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).xport) as usize - ptr as usize }, + 52usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_addr_kill), + "::", + stringify!(xport) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_state_kill { + pub psk_af: sa_family_t, + pub psk_proto: u_int8_t, + pub psk_proto_variant: u_int8_t, + pub _pad: u_int8_t, + pub psk_src: pfioc_state_addr_kill, + pub psk_dst: pfioc_state_addr_kill, + pub psk_ifname: [::std::os::raw::c_char; 16usize], + pub psk_ownername: [::std::os::raw::c_char; 64usize], +} +#[test] +fn bindgen_test_layout_pfioc_state_kill() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 216usize, + concat!("Size of: ", stringify!(pfioc_state_kill)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_state_kill)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_af) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_af) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_proto) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_proto) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_proto_variant) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_proto_variant) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pad) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(_pad) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_src) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_src) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_dst) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_dst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_ifname) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_ownername) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_ownername) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_states { + pub ps_len: ::std::os::raw::c_int, + pub ps_u: pfioc_states__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfioc_states__bindgen_ty_1 { + pub psu_buf: caddr_t, + pub psu_states: *mut pfsync_state, +} +#[test] +fn bindgen_test_layout_pfioc_states__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_states__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_states__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psu_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states__bindgen_ty_1), + "::", + stringify!(psu_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psu_states) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states__bindgen_ty_1), + "::", + stringify!(psu_states) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_states() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_states)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_states), "::", stringify!(ps_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_u) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_states), "::", stringify!(ps_u)) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_token { + pub token_value: u_int64_t, + pub timestamp: u_int64_t, + pub pid: pid_t, + pub proc_name: [::std::os::raw::c_char; 64usize], +} +#[test] +fn bindgen_test_layout_pfioc_token() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 84usize, + concat!("Size of: ", stringify!(pfioc_token)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfioc_token)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).token_value) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_token), + "::", + stringify!(token_value) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timestamp) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_token), + "::", + stringify!(timestamp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pid) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_token), "::", stringify!(pid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proc_name) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfioc_token), + "::", + stringify!(proc_name) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_kernel_token { + pub next: pfioc_kernel_token__bindgen_ty_1, + pub token: pfioc_token, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_kernel_token__bindgen_ty_1 { + pub sle_next: *mut pfioc_kernel_token, +} +#[test] +fn bindgen_test_layout_pfioc_kernel_token__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_kernel_token__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_kernel_token__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_kernel_token__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_kernel_token() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(pfioc_kernel_token)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_kernel_token)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_kernel_token), + "::", + stringify!(next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).token) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_kernel_token), + "::", + stringify!(token) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_remove_token { + pub token_value: u_int64_t, + pub refcount: u_int64_t, +} +#[test] +fn bindgen_test_layout_pfioc_remove_token() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_remove_token)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_remove_token)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).token_value) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_remove_token), + "::", + stringify!(token_value) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).refcount) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_remove_token), + "::", + stringify!(refcount) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_tokens { + pub size: ::std::os::raw::c_int, + pub pgt_u: pfioc_tokens__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfioc_tokens__bindgen_ty_1 { + pub pgtu_buf: caddr_t, + pub pgtu_tokens: *mut pfioc_token, +} +#[test] +fn bindgen_test_layout_pfioc_tokens__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_tokens__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_tokens__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pgtu_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_tokens__bindgen_ty_1), + "::", + stringify!(pgtu_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pgtu_tokens) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_tokens__bindgen_ty_1), + "::", + stringify!(pgtu_tokens) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_tokens() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_tokens)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_tokens)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).size) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_tokens), "::", stringify!(size)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pgt_u) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_tokens), "::", stringify!(pgt_u)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_src_nodes { + pub psn_len: ::std::os::raw::c_int, + pub psn_u: pfioc_src_nodes__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfioc_src_nodes__bindgen_ty_1 { + pub psu_buf: caddr_t, + pub psu_src_nodes: *mut pf_src_node, +} +#[test] +fn bindgen_test_layout_pfioc_src_nodes__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_src_nodes__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_src_nodes__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psu_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes__bindgen_ty_1), + "::", + stringify!(psu_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psu_src_nodes) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes__bindgen_ty_1), + "::", + stringify!(psu_src_nodes) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_src_nodes() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_src_nodes)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_src_nodes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psn_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes), + "::", + stringify!(psn_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psn_u) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes), + "::", + stringify!(psn_u) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_if { + pub ifname: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_pfioc_if() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_if)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfioc_if)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_if), "::", stringify!(ifname)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_tm { + pub timeout: ::std::os::raw::c_int, + pub seconds: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfioc_tm() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_tm)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_tm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_tm), "::", stringify!(timeout)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seconds) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_tm), "::", stringify!(seconds)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_limit { + pub index: ::std::os::raw::c_int, + pub limit: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_pfioc_limit() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_limit)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_limit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).index) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_limit), "::", stringify!(index)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_limit), "::", stringify!(limit)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_altq { + pub action: u_int32_t, + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub altq: pf_altq, +} +#[test] +fn bindgen_test_layout_pfioc_altq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 344usize, + concat!("Size of: ", stringify!(pfioc_altq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_altq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_altq), "::", stringify!(action)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_altq), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_altq), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).altq) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_altq), "::", stringify!(altq)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_qstats { + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub buf: *mut ::std::os::raw::c_void, + pub nbytes: ::std::os::raw::c_int, + pub scheduler: u_int8_t, +} +#[test] +fn bindgen_test_layout_pfioc_qstats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pfioc_qstats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_qstats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_qstats), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_qstats), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).buf) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_qstats), "::", stringify!(buf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nbytes) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_qstats), "::", stringify!(nbytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scheduler) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfioc_qstats), + "::", + stringify!(scheduler) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_ruleset { + pub nr: u_int32_t, + pub path: [::std::os::raw::c_char; 1024usize], + pub name: [::std::os::raw::c_char; 64usize], +} +#[test] +fn bindgen_test_layout_pfioc_ruleset() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1092usize, + concat!("Size of: ", stringify!(pfioc_ruleset)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_ruleset), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).path) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_ruleset), "::", stringify!(path)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, + 1028usize, + concat!("Offset of field: ", stringify!(pfioc_ruleset), "::", stringify!(name)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_trans { + pub size: ::std::os::raw::c_int, + pub esize: ::std::os::raw::c_int, + pub array: *mut pfioc_trans_pfioc_trans_e, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_trans_pfioc_trans_e { + pub rs_num: ::std::os::raw::c_int, + pub anchor: [::std::os::raw::c_char; 1024usize], + pub ticket: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfioc_trans_pfioc_trans_e() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1032usize, + concat!("Size of: ", stringify!(pfioc_trans_pfioc_trans_e)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_trans_pfioc_trans_e)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rs_num) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_trans_pfioc_trans_e), + "::", + stringify!(rs_num) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pfioc_trans_pfioc_trans_e), + "::", + stringify!(anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 1028usize, + concat!( + "Offset of field: ", + stringify!(pfioc_trans_pfioc_trans_e), + "::", + stringify!(ticket) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_trans() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_trans)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_trans)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).size) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_trans), "::", stringify!(size)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).esize) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_trans), "::", stringify!(esize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).array) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_trans), "::", stringify!(array)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_table { + pub pfrio_table: pfr_table, + pub pfrio_buffer: *mut ::std::os::raw::c_void, + pub pfrio_esize: ::std::os::raw::c_int, + pub pfrio_size: ::std::os::raw::c_int, + pub pfrio_size2: ::std::os::raw::c_int, + pub pfrio_nadd: ::std::os::raw::c_int, + pub pfrio_ndel: ::std::os::raw::c_int, + pub pfrio_nchange: ::std::os::raw::c_int, + pub pfrio_flags: ::std::os::raw::c_int, + pub pfrio_ticket: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfioc_table() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1104usize, + concat!("Size of: ", stringify!(pfioc_table)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_table)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_table) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_table) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_buffer) as usize - ptr as usize }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_buffer) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_esize) as usize - ptr as usize }, + 1072usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_esize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_size) as usize - ptr as usize }, + 1076usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_size2) as usize - ptr as usize }, + 1080usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_size2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_nadd) as usize - ptr as usize }, + 1084usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_nadd) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_ndel) as usize - ptr as usize }, + 1088usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_ndel) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_nchange) as usize - ptr as usize }, + 1092usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_nchange) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_flags) as usize - ptr as usize }, + 1096usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_ticket) as usize - ptr as usize }, + 1100usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_ticket) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_iface { + pub pfiio_name: [::std::os::raw::c_char; 16usize], + pub pfiio_buffer: *mut ::std::os::raw::c_void, + pub pfiio_esize: ::std::os::raw::c_int, + pub pfiio_size: ::std::os::raw::c_int, + pub pfiio_nzero: ::std::os::raw::c_int, + pub pfiio_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfioc_iface() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pfioc_iface)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_iface)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_buffer) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_buffer) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_esize) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_esize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_size) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_nzero) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_nzero) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_flags) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_flags) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ifspeed { + pub ifname: [::std::os::raw::c_char; 16usize], + pub baudrate: u_int64_t, +} +#[test] +fn bindgen_test_layout_pf_ifspeed() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_ifspeed)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ifspeed)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_ifspeed), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).baudrate) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_ifspeed), "::", stringify!(baudrate)) + ); +} +extern "C" { + pub static mut pf_anchors: pf_anchor_global; +} +extern "C" { + pub static mut pf_main_anchor: pf_anchor; +} +extern "C" { + pub fn pf_get_ruleset_number(arg1: u_int8_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_init_ruleset(arg1: *mut pf_ruleset); +} +extern "C" { + pub fn pf_anchor_setup( + arg1: *mut pf_rule, + arg2: *const pf_ruleset, + arg3: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_anchor_copyout( + arg1: *const pf_ruleset, + arg2: *const pf_rule, + arg3: *mut pfioc_rule, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_anchor_remove(arg1: *mut pf_rule); +} +extern "C" { + pub fn pf_remove_if_empty_ruleset(arg1: *mut pf_ruleset); +} +extern "C" { + pub fn pf_find_anchor(arg1: *const ::std::os::raw::c_char) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_find_ruleset(arg1: *const ::std::os::raw::c_char) -> *mut pf_ruleset; +} +extern "C" { + pub fn pf_find_ruleset_with_owner( + arg1: *const ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + arg3: ::std::os::raw::c_int, + arg4: *mut ::std::os::raw::c_int, + ) -> *mut pf_ruleset; +} +extern "C" { + pub fn pf_find_or_create_ruleset(arg1: *const ::std::os::raw::c_char) -> *mut pf_ruleset; +} +extern "C" { + pub fn pf_rs_initialize(); +} +pub type __builtin_va_list = [__va_list_tag; 1usize]; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __va_list_tag { + pub gp_offset: ::std::os::raw::c_uint, + pub fp_offset: ::std::os::raw::c_uint, + pub overflow_arg_area: *mut ::std::os::raw::c_void, + pub reg_save_area: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout___va_list_tag() { + const UNINIT: ::std::mem::MaybeUninit<__va_list_tag> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__va_list_tag>(), + 24usize, + concat!("Size of: ", stringify!(__va_list_tag)) + ); + assert_eq!( + ::std::mem::align_of::<__va_list_tag>(), + 8usize, + concat!("Alignment of ", stringify!(__va_list_tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gp_offset) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(gp_offset) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_offset) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(fp_offset) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).overflow_arg_area) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(overflow_arg_area) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reg_save_area) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(reg_save_area) + ) + ); +} diff --git a/tproxy_tokio/src/tcp/bsd/pfvar_bindgen_openbsd.rs b/tproxy_tokio/src/tcp/bsd/pfvar_bindgen_openbsd.rs new file mode 100644 index 0000000..17d8130 --- /dev/null +++ b/tproxy_tokio/src/tcp/bsd/pfvar_bindgen_openbsd.rs @@ -0,0 +1,13966 @@ +// automatically generated by rust-bindgen 0.69.4 + +pub const __ISO_C_VISIBLE: u32 = 2011; +pub const __XPG_VISIBLE: u32 = 700; +pub const __POSIX_VISIBLE: u32 = 200809; +pub const __BSD_VISIBLE: u32 = 1; +pub const _STACKALIGNBYTES: u32 = 15; +pub const _MAX_PAGE_SHIFT: u32 = 12; +pub const INT8_MIN: i32 = -128; +pub const INT16_MIN: i32 = -32768; +pub const INT32_MIN: i32 = -2147483648; +pub const INT64_MIN: i64 = -9223372036854775808; +pub const INT8_MAX: u32 = 127; +pub const INT16_MAX: u32 = 32767; +pub const INT32_MAX: u32 = 2147483647; +pub const INT64_MAX: u64 = 9223372036854775807; +pub const UINT8_MAX: u32 = 255; +pub const UINT16_MAX: u32 = 65535; +pub const UINT32_MAX: u32 = 4294967295; +pub const UINT64_MAX: i32 = -1; +pub const INT_LEAST8_MIN: i32 = -128; +pub const INT_LEAST16_MIN: i32 = -32768; +pub const INT_LEAST32_MIN: i32 = -2147483648; +pub const INT_LEAST64_MIN: i64 = -9223372036854775808; +pub const INT_LEAST8_MAX: u32 = 127; +pub const INT_LEAST16_MAX: u32 = 32767; +pub const INT_LEAST32_MAX: u32 = 2147483647; +pub const INT_LEAST64_MAX: u64 = 9223372036854775807; +pub const UINT_LEAST8_MAX: u32 = 255; +pub const UINT_LEAST16_MAX: u32 = 65535; +pub const UINT_LEAST32_MAX: u32 = 4294967295; +pub const UINT_LEAST64_MAX: i32 = -1; +pub const INTPTR_MIN: i64 = -9223372036854775808; +pub const INTPTR_MAX: u64 = 9223372036854775807; +pub const UINTPTR_MAX: i32 = -1; +pub const INTMAX_MIN: i64 = -9223372036854775808; +pub const INTMAX_MAX: u64 = 9223372036854775807; +pub const UINTMAX_MAX: i32 = -1; +pub const PTRDIFF_MIN: i64 = -9223372036854775808; +pub const PTRDIFF_MAX: u64 = 9223372036854775807; +pub const SIG_ATOMIC_MIN: i32 = -2147483648; +pub const SIG_ATOMIC_MAX: u32 = 2147483647; +pub const SIZE_MAX: i32 = -1; +pub const WCHAR_MIN: i32 = -2147483648; +pub const WCHAR_MAX: u32 = 2147483647; +pub const WINT_MIN: i32 = -2147483648; +pub const WINT_MAX: u32 = 2147483647; +pub const UIO_MAXIOV: u32 = 1024; +pub const _LITTLE_ENDIAN: u32 = 1234; +pub const _BIG_ENDIAN: u32 = 4321; +pub const _PDP_ENDIAN: u32 = 3412; +pub const _QUAD_HIGHWORD: u32 = 1; +pub const _QUAD_LOWWORD: u32 = 0; +pub const LITTLE_ENDIAN: u32 = 1234; +pub const BIG_ENDIAN: u32 = 4321; +pub const PDP_ENDIAN: u32 = 3412; +pub const SOCK_STREAM: u32 = 1; +pub const SOCK_DGRAM: u32 = 2; +pub const SOCK_RAW: u32 = 3; +pub const SOCK_RDM: u32 = 4; +pub const SOCK_SEQPACKET: u32 = 5; +pub const SOCK_CLOEXEC: u32 = 32768; +pub const SOCK_NONBLOCK: u32 = 16384; +pub const SOCK_DNS: u32 = 4096; +pub const SO_DEBUG: u32 = 1; +pub const SO_ACCEPTCONN: u32 = 2; +pub const SO_REUSEADDR: u32 = 4; +pub const SO_KEEPALIVE: u32 = 8; +pub const SO_DONTROUTE: u32 = 16; +pub const SO_BROADCAST: u32 = 32; +pub const SO_USELOOPBACK: u32 = 64; +pub const SO_LINGER: u32 = 128; +pub const SO_OOBINLINE: u32 = 256; +pub const SO_REUSEPORT: u32 = 512; +pub const SO_TIMESTAMP: u32 = 2048; +pub const SO_BINDANY: u32 = 4096; +pub const SO_ZEROIZE: u32 = 8192; +pub const SO_SNDBUF: u32 = 4097; +pub const SO_RCVBUF: u32 = 4098; +pub const SO_SNDLOWAT: u32 = 4099; +pub const SO_RCVLOWAT: u32 = 4100; +pub const SO_SNDTIMEO: u32 = 4101; +pub const SO_RCVTIMEO: u32 = 4102; +pub const SO_ERROR: u32 = 4103; +pub const SO_TYPE: u32 = 4104; +pub const SO_NETPROC: u32 = 4128; +pub const SO_RTABLE: u32 = 4129; +pub const SO_PEERCRED: u32 = 4130; +pub const SO_SPLICE: u32 = 4131; +pub const SO_DOMAIN: u32 = 4132; +pub const SO_PROTOCOL: u32 = 4133; +pub const RT_TABLEID_MAX: u32 = 255; +pub const RT_TABLEID_BITS: u32 = 8; +pub const RT_TABLEID_MASK: u32 = 255; +pub const SOL_SOCKET: u32 = 65535; +pub const AF_UNSPEC: u32 = 0; +pub const AF_UNIX: u32 = 1; +pub const AF_LOCAL: u32 = 1; +pub const AF_INET: u32 = 2; +pub const AF_IMPLINK: u32 = 3; +pub const AF_PUP: u32 = 4; +pub const AF_CHAOS: u32 = 5; +pub const AF_NS: u32 = 6; +pub const AF_ISO: u32 = 7; +pub const AF_OSI: u32 = 7; +pub const AF_ECMA: u32 = 8; +pub const AF_DATAKIT: u32 = 9; +pub const AF_CCITT: u32 = 10; +pub const AF_SNA: u32 = 11; +pub const AF_DECnet: u32 = 12; +pub const AF_DLI: u32 = 13; +pub const AF_LAT: u32 = 14; +pub const AF_HYLINK: u32 = 15; +pub const AF_APPLETALK: u32 = 16; +pub const AF_ROUTE: u32 = 17; +pub const AF_LINK: u32 = 18; +pub const pseudo_AF_XTP: u32 = 19; +pub const AF_COIP: u32 = 20; +pub const AF_CNT: u32 = 21; +pub const pseudo_AF_RTIP: u32 = 22; +pub const AF_IPX: u32 = 23; +pub const AF_INET6: u32 = 24; +pub const pseudo_AF_PIP: u32 = 25; +pub const AF_ISDN: u32 = 26; +pub const AF_E164: u32 = 26; +pub const AF_NATM: u32 = 27; +pub const AF_ENCAP: u32 = 28; +pub const AF_SIP: u32 = 29; +pub const AF_KEY: u32 = 30; +pub const pseudo_AF_HDRCMPLT: u32 = 31; +pub const AF_BLUETOOTH: u32 = 32; +pub const AF_MPLS: u32 = 33; +pub const pseudo_AF_PFLOW: u32 = 34; +pub const pseudo_AF_PIPEX: u32 = 35; +pub const AF_MAX: u32 = 36; +pub const PF_UNSPEC: u32 = 0; +pub const PF_LOCAL: u32 = 1; +pub const PF_UNIX: u32 = 1; +pub const PF_INET: u32 = 2; +pub const PF_IMPLINK: u32 = 3; +pub const PF_PUP: u32 = 4; +pub const PF_CHAOS: u32 = 5; +pub const PF_NS: u32 = 6; +pub const PF_ISO: u32 = 7; +pub const PF_OSI: u32 = 7; +pub const PF_ECMA: u32 = 8; +pub const PF_DATAKIT: u32 = 9; +pub const PF_CCITT: u32 = 10; +pub const PF_SNA: u32 = 11; +pub const PF_DECnet: u32 = 12; +pub const PF_DLI: u32 = 13; +pub const PF_LAT: u32 = 14; +pub const PF_HYLINK: u32 = 15; +pub const PF_APPLETALK: u32 = 16; +pub const PF_ROUTE: u32 = 17; +pub const PF_LINK: u32 = 18; +pub const PF_XTP: u32 = 19; +pub const PF_COIP: u32 = 20; +pub const PF_CNT: u32 = 21; +pub const PF_IPX: u32 = 23; +pub const PF_INET6: u32 = 24; +pub const PF_RTIP: u32 = 22; +pub const PF_PIP: u32 = 25; +pub const PF_ISDN: u32 = 26; +pub const PF_NATM: u32 = 27; +pub const PF_ENCAP: u32 = 28; +pub const PF_SIP: u32 = 29; +pub const PF_KEY: u32 = 30; +pub const PF_BPF: u32 = 31; +pub const PF_BLUETOOTH: u32 = 32; +pub const PF_MPLS: u32 = 33; +pub const PF_PFLOW: u32 = 34; +pub const PF_PIPEX: u32 = 35; +pub const PF_MAX: u32 = 36; +pub const SHUT_RD: u32 = 0; +pub const SHUT_WR: u32 = 1; +pub const SHUT_RDWR: u32 = 2; +pub const NET_MAXID: u32 = 36; +pub const NET_RT_DUMP: u32 = 1; +pub const NET_RT_FLAGS: u32 = 2; +pub const NET_RT_IFLIST: u32 = 3; +pub const NET_RT_STATS: u32 = 4; +pub const NET_RT_TABLE: u32 = 5; +pub const NET_RT_IFNAMES: u32 = 6; +pub const NET_RT_SOURCE: u32 = 7; +pub const NET_RT_MAXID: u32 = 8; +pub const NET_UNIX_INFLIGHT: u32 = 6; +pub const NET_UNIX_DEFERRED: u32 = 7; +pub const NET_UNIX_MAXID: u32 = 8; +pub const UNPCTL_RECVSPACE: u32 = 1; +pub const UNPCTL_SENDSPACE: u32 = 2; +pub const NET_UNIX_PROTO_MAXID: u32 = 3; +pub const NET_LINK_IFRXQ: u32 = 1; +pub const NET_LINK_MAXID: u32 = 2; +pub const NET_LINK_IFRXQ_PRESSURE_RETURN: u32 = 1; +pub const NET_LINK_IFRXQ_PRESSURE_DROP: u32 = 2; +pub const NET_LINK_IFRXQ_MAXID: u32 = 3; +pub const NET_KEY_SADB_DUMP: u32 = 1; +pub const NET_KEY_SPD_DUMP: u32 = 2; +pub const NET_KEY_MAXID: u32 = 3; +pub const NET_BPF_BUFSIZE: u32 = 1; +pub const NET_BPF_MAXBUFSIZE: u32 = 2; +pub const NET_BPF_MAXID: u32 = 3; +pub const NET_PFLOW_STATS: u32 = 1; +pub const NET_PFLOW_MAXID: u32 = 2; +pub const SOMAXCONN: u32 = 128; +pub const MSG_OOB: u32 = 1; +pub const MSG_PEEK: u32 = 2; +pub const MSG_DONTROUTE: u32 = 4; +pub const MSG_EOR: u32 = 8; +pub const MSG_TRUNC: u32 = 16; +pub const MSG_CTRUNC: u32 = 32; +pub const MSG_WAITALL: u32 = 64; +pub const MSG_DONTWAIT: u32 = 128; +pub const MSG_BCAST: u32 = 256; +pub const MSG_MCAST: u32 = 512; +pub const MSG_NOSIGNAL: u32 = 1024; +pub const MSG_CMSG_CLOEXEC: u32 = 2048; +pub const MSG_WAITFORONE: u32 = 4096; +pub const SCM_RIGHTS: u32 = 1; +pub const SCM_TIMESTAMP: u32 = 4; +pub const IF_NAMESIZE: u32 = 16; +pub const FD_SETSIZE: u32 = 1024; +pub const __NBBY: u32 = 8; +pub const NBBY: u32 = 8; +pub const DST_NONE: u32 = 0; +pub const DST_USA: u32 = 1; +pub const DST_AUST: u32 = 2; +pub const DST_WET: u32 = 3; +pub const DST_MET: u32 = 4; +pub const DST_EET: u32 = 5; +pub const DST_CAN: u32 = 6; +pub const ITIMER_REAL: u32 = 0; +pub const ITIMER_VIRTUAL: u32 = 1; +pub const ITIMER_PROF: u32 = 2; +pub const CLOCKS_PER_SEC: u32 = 100; +pub const CLOCK_REALTIME: u32 = 0; +pub const CLOCK_PROCESS_CPUTIME_ID: u32 = 2; +pub const CLOCK_MONOTONIC: u32 = 3; +pub const CLOCK_THREAD_CPUTIME_ID: u32 = 4; +pub const CLOCK_UPTIME: u32 = 5; +pub const CLOCK_BOOTTIME: u32 = 6; +pub const TIMER_RELTIME: u32 = 0; +pub const TIMER_ABSTIME: u32 = 1; +pub const CLK_TCK: u32 = 100; +pub const TIME_UTC: u32 = 1; +pub const MCLPOOLS: u32 = 8; +pub const IFQ_NQUEUES: u32 = 8; +pub const IFQ_MINPRIO: u32 = 0; +pub const IFQ_MAXPRIO: u32 = 7; +pub const IFQ_DEFPRIO: u32 = 3; +pub const LINK_STATE_UNKNOWN: u32 = 0; +pub const LINK_STATE_INVALID: u32 = 1; +pub const LINK_STATE_DOWN: u32 = 2; +pub const LINK_STATE_KALIVE_DOWN: u32 = 3; +pub const LINK_STATE_UP: u32 = 4; +pub const LINK_STATE_HALF_DUPLEX: u32 = 5; +pub const LINK_STATE_FULL_DUPLEX: u32 = 6; +pub const IFNAMSIZ: u32 = 16; +pub const IFDESCRSIZE: u32 = 64; +pub const IFF_UP: u32 = 1; +pub const IFF_BROADCAST: u32 = 2; +pub const IFF_DEBUG: u32 = 4; +pub const IFF_LOOPBACK: u32 = 8; +pub const IFF_POINTOPOINT: u32 = 16; +pub const IFF_STATICARP: u32 = 32; +pub const IFF_RUNNING: u32 = 64; +pub const IFF_NOARP: u32 = 128; +pub const IFF_PROMISC: u32 = 256; +pub const IFF_ALLMULTI: u32 = 512; +pub const IFF_OACTIVE: u32 = 1024; +pub const IFF_SIMPLEX: u32 = 2048; +pub const IFF_LINK0: u32 = 4096; +pub const IFF_LINK1: u32 = 8192; +pub const IFF_LINK2: u32 = 16384; +pub const IFF_MULTICAST: u32 = 32768; +pub const IFF_CANTCHANGE: u32 = 36434; +pub const IFXF_MPSAFE: u32 = 1; +pub const IFXF_CLONED: u32 = 2; +pub const IFXF_AUTOCONF6TEMP: u32 = 4; +pub const IFXF_MPLS: u32 = 8; +pub const IFXF_WOL: u32 = 16; +pub const IFXF_AUTOCONF6: u32 = 32; +pub const IFXF_INET6_NOSOII: u32 = 64; +pub const IFXF_AUTOCONF4: u32 = 128; +pub const IFXF_MONITOR: u32 = 256; +pub const IFXF_LRO: u32 = 512; +pub const IFXF_CANTCHANGE: u32 = 3; +pub const IFCAP_CSUM_IPv4: u32 = 1; +pub const IFCAP_CSUM_TCPv4: u32 = 2; +pub const IFCAP_CSUM_UDPv4: u32 = 4; +pub const IFCAP_VLAN_MTU: u32 = 16; +pub const IFCAP_VLAN_HWTAGGING: u32 = 32; +pub const IFCAP_CSUM_TCPv6: u32 = 128; +pub const IFCAP_CSUM_UDPv6: u32 = 256; +pub const IFCAP_TSOv4: u32 = 4096; +pub const IFCAP_TSOv6: u32 = 8192; +pub const IFCAP_LRO: u32 = 16384; +pub const IFCAP_WOL: u32 = 32768; +pub const IFCAP_CSUM_MASK: u32 = 391; +pub const IFQCTL_LEN: u32 = 1; +pub const IFQCTL_MAXLEN: u32 = 2; +pub const IFQCTL_DROPS: u32 = 3; +pub const IFQCTL_CONGESTION: u32 = 4; +pub const IFQCTL_MAXID: u32 = 5; +pub const IFAN_ARRIVAL: u32 = 0; +pub const IFAN_DEPARTURE: u32 = 1; +pub const IFG_ALL: &[u8; 4] = b"all\0"; +pub const IFG_EGRESS: &[u8; 7] = b"egress\0"; +pub const IF_HDRPRIO_MIN: u32 = 0; +pub const IF_HDRPRIO_MAX: u32 = 7; +pub const IF_HDRPRIO_PACKET: i32 = -1; +pub const IF_HDRPRIO_PAYLOAD: i32 = -2; +pub const IF_HDRPRIO_OUTER: i32 = -3; +pub const IF_PWE3_ETHERNET: u32 = 1; +pub const IF_PWE3_IP: u32 = 2; +pub const IFLR_PREFIX: u32 = 32768; +pub const IFSFF_ADDR_EEPROM: u32 = 160; +pub const IFSFF_ADDR_DDM: u32 = 162; +pub const IFSFF_DATA_LEN: u32 = 256; +pub const ARPHRD_ETHER: u32 = 1; +pub const ARPHRD_IEEE802: u32 = 6; +pub const ARPHRD_FRELAY: u32 = 15; +pub const ARPHRD_IEEE1394: u32 = 24; +pub const ARPOP_REQUEST: u32 = 1; +pub const ARPOP_REPLY: u32 = 2; +pub const ARPOP_REVREQUEST: u32 = 3; +pub const ARPOP_REVREPLY: u32 = 4; +pub const ARPOP_INVREQUEST: u32 = 8; +pub const ARPOP_INVREPLY: u32 = 9; +pub const ATF_INUSE: u32 = 1; +pub const ATF_COM: u32 = 2; +pub const ATF_PERM: u32 = 4; +pub const ATF_PUBL: u32 = 8; +pub const ATF_USETRAILERS: u32 = 16; +pub const SPLAY_NEGINF: i32 = -1; +pub const SPLAY_INF: u32 = 1; +pub const RB_BLACK: u32 = 0; +pub const RB_RED: u32 = 1; +pub const RB_NEGINF: i32 = -1; +pub const RB_INF: u32 = 1; +pub const LO_CLASSFLAGS: u32 = 65535; +pub const LO_INITIALIZED: u32 = 65536; +pub const LO_WITNESS: u32 = 131072; +pub const LO_QUIET: u32 = 262144; +pub const LO_RECURSABLE: u32 = 524288; +pub const LO_SLEEPABLE: u32 = 1048576; +pub const LO_UPGRADABLE: u32 = 2097152; +pub const LO_DUPOK: u32 = 4194304; +pub const LO_IS_VNODE: u32 = 8388608; +pub const LO_CLASSMASK: u32 = 251658240; +pub const LO_NOPROFILE: u32 = 268435456; +pub const LO_NEW: u32 = 536870912; +pub const LO_CLASSSHIFT: u32 = 24; +pub const RWL_DUPOK: u32 = 1; +pub const RWL_NOWITNESS: u32 = 2; +pub const RWL_IS_VNODE: u32 = 4; +pub const RWLOCK_WAIT: u32 = 1; +pub const RWLOCK_WRWANT: u32 = 2; +pub const RWLOCK_WRLOCK: u32 = 4; +pub const RWLOCK_MASK: u32 = 7; +pub const RWLOCK_READER_SHIFT: u32 = 3; +pub const RWLOCK_READ_INCR: u32 = 8; +pub const RW_WRITE: u32 = 1; +pub const RW_READ: u32 = 2; +pub const RW_DOWNGRADE: u32 = 4; +pub const RW_OPMASK: u32 = 7; +pub const RW_INTR: u32 = 16; +pub const RW_SLEEPFAIL: u32 = 32; +pub const RW_NOSLEEP: u32 = 64; +pub const RW_RECURSEFAIL: u32 = 128; +pub const RW_DUPOK: u32 = 256; +pub const RW_WRITE_OTHER: u32 = 256; +pub const ARG_MAX: u32 = 524288; +pub const CHILD_MAX: u32 = 80; +pub const LINK_MAX: u32 = 32767; +pub const MAX_CANON: u32 = 255; +pub const MAX_INPUT: u32 = 255; +pub const NAME_MAX: u32 = 255; +pub const NGROUPS_MAX: u32 = 16; +pub const OPEN_MAX: u32 = 64; +pub const PATH_MAX: u32 = 1024; +pub const PIPE_BUF: u32 = 512; +pub const SYMLINK_MAX: u32 = 1024; +pub const SYMLOOP_MAX: u32 = 32; +pub const BC_DIM_MAX: u32 = 65535; +pub const COLL_WEIGHTS_MAX: u32 = 2; +pub const EXPR_NEST_MAX: u32 = 32; +pub const LINE_MAX: u32 = 2048; +pub const RE_DUP_MAX: u32 = 255; +pub const IOV_MAX: u32 = 1024; +pub const NZERO: u32 = 20; +pub const TTY_NAME_MAX: u32 = 260; +pub const LOGIN_NAME_MAX: u32 = 32; +pub const HOST_NAME_MAX: u32 = 255; +pub const _MAXCOMLEN: u32 = 24; +pub const TIMEOUT_PROC: u32 = 1; +pub const TIMEOUT_ONQUEUE: u32 = 2; +pub const TIMEOUT_INITIALIZED: u32 = 4; +pub const TIMEOUT_TRIGGERED: u32 = 8; +pub const TIMEOUT_MPSAFE: u32 = 16; +pub const IPPROTO_IP: u32 = 0; +pub const IPPROTO_HOPOPTS: u32 = 0; +pub const IPPROTO_ICMP: u32 = 1; +pub const IPPROTO_IGMP: u32 = 2; +pub const IPPROTO_GGP: u32 = 3; +pub const IPPROTO_IPIP: u32 = 4; +pub const IPPROTO_IPV4: u32 = 4; +pub const IPPROTO_TCP: u32 = 6; +pub const IPPROTO_EGP: u32 = 8; +pub const IPPROTO_PUP: u32 = 12; +pub const IPPROTO_UDP: u32 = 17; +pub const IPPROTO_IDP: u32 = 22; +pub const IPPROTO_TP: u32 = 29; +pub const IPPROTO_IPV6: u32 = 41; +pub const IPPROTO_ROUTING: u32 = 43; +pub const IPPROTO_FRAGMENT: u32 = 44; +pub const IPPROTO_RSVP: u32 = 46; +pub const IPPROTO_GRE: u32 = 47; +pub const IPPROTO_ESP: u32 = 50; +pub const IPPROTO_AH: u32 = 51; +pub const IPPROTO_MOBILE: u32 = 55; +pub const IPPROTO_ICMPV6: u32 = 58; +pub const IPPROTO_NONE: u32 = 59; +pub const IPPROTO_DSTOPTS: u32 = 60; +pub const IPPROTO_EON: u32 = 80; +pub const IPPROTO_ETHERIP: u32 = 97; +pub const IPPROTO_ENCAP: u32 = 98; +pub const IPPROTO_PIM: u32 = 103; +pub const IPPROTO_IPCOMP: u32 = 108; +pub const IPPROTO_CARP: u32 = 112; +pub const IPPROTO_SCTP: u32 = 132; +pub const IPPROTO_UDPLITE: u32 = 136; +pub const IPPROTO_MPLS: u32 = 137; +pub const IPPROTO_PFSYNC: u32 = 240; +pub const IPPROTO_RAW: u32 = 255; +pub const IPPROTO_MAX: u32 = 256; +pub const IPPROTO_DIVERT: u32 = 258; +pub const IPPORT_RESERVED: u32 = 1024; +pub const IPPORT_USERRESERVED: u32 = 49151; +pub const IPPORT_HIFIRSTAUTO: u32 = 49152; +pub const IPPORT_HILASTAUTO: u32 = 65535; +pub const IPPROTO_DONE: u32 = 257; +pub const IN_CLASSA_NSHIFT: u32 = 24; +pub const IN_CLASSA_MAX: u32 = 128; +pub const IN_CLASSB_NSHIFT: u32 = 16; +pub const IN_CLASSB_MAX: u32 = 65536; +pub const IN_CLASSC_NSHIFT: u32 = 8; +pub const IN_CLASSD_NSHIFT: u32 = 28; +pub const IN_RFC3021_NSHIFT: u32 = 31; +pub const IN_LOOPBACKNET: u32 = 127; +pub const IP_OPTIONS: u32 = 1; +pub const IP_HDRINCL: u32 = 2; +pub const IP_TOS: u32 = 3; +pub const IP_TTL: u32 = 4; +pub const IP_RECVOPTS: u32 = 5; +pub const IP_RECVRETOPTS: u32 = 6; +pub const IP_RECVDSTADDR: u32 = 7; +pub const IP_RETOPTS: u32 = 8; +pub const IP_MULTICAST_IF: u32 = 9; +pub const IP_MULTICAST_TTL: u32 = 10; +pub const IP_MULTICAST_LOOP: u32 = 11; +pub const IP_ADD_MEMBERSHIP: u32 = 12; +pub const IP_DROP_MEMBERSHIP: u32 = 13; +pub const IP_PORTRANGE: u32 = 19; +pub const IP_AUTH_LEVEL: u32 = 20; +pub const IP_ESP_TRANS_LEVEL: u32 = 21; +pub const IP_ESP_NETWORK_LEVEL: u32 = 22; +pub const IP_IPSEC_LOCAL_ID: u32 = 23; +pub const IP_IPSEC_REMOTE_ID: u32 = 24; +pub const IP_IPSEC_LOCAL_CRED: u32 = 25; +pub const IP_IPSEC_REMOTE_CRED: u32 = 26; +pub const IP_IPSEC_LOCAL_AUTH: u32 = 27; +pub const IP_IPSEC_REMOTE_AUTH: u32 = 28; +pub const IP_IPCOMP_LEVEL: u32 = 29; +pub const IP_RECVIF: u32 = 30; +pub const IP_RECVTTL: u32 = 31; +pub const IP_MINTTL: u32 = 32; +pub const IP_RECVDSTPORT: u32 = 33; +pub const IP_PIPEX: u32 = 34; +pub const IP_RECVRTABLE: u32 = 35; +pub const IP_IPSECFLOWINFO: u32 = 36; +pub const IP_IPDEFTTL: u32 = 37; +pub const IP_SENDSRCADDR: u32 = 7; +pub const IP_RTABLE: u32 = 4129; +pub const IPSEC_LEVEL_BYPASS: u32 = 0; +pub const IPSEC_LEVEL_NONE: u32 = 0; +pub const IPSEC_LEVEL_AVAIL: u32 = 1; +pub const IPSEC_LEVEL_USE: u32 = 2; +pub const IPSEC_LEVEL_REQUIRE: u32 = 3; +pub const IPSEC_LEVEL_UNIQUE: u32 = 4; +pub const IPSEC_LEVEL_DEFAULT: u32 = 1; +pub const IPSEC_AUTH_LEVEL_DEFAULT: u32 = 1; +pub const IPSEC_ESP_TRANS_LEVEL_DEFAULT: u32 = 1; +pub const IPSEC_ESP_NETWORK_LEVEL_DEFAULT: u32 = 1; +pub const IPSEC_IPCOMP_LEVEL_DEFAULT: u32 = 1; +pub const IP_DEFAULT_MULTICAST_TTL: u32 = 1; +pub const IP_DEFAULT_MULTICAST_LOOP: u32 = 1; +pub const IP_MIN_MEMBERSHIPS: u32 = 15; +pub const IP_MAX_MEMBERSHIPS: u32 = 4095; +pub const IP_PORTRANGE_DEFAULT: u32 = 0; +pub const IP_PORTRANGE_HIGH: u32 = 1; +pub const IP_PORTRANGE_LOW: u32 = 2; +pub const INET_ADDRSTRLEN: u32 = 16; +pub const IPPROTO_MAXID: u32 = 259; +pub const IPCTL_FORWARDING: u32 = 1; +pub const IPCTL_SENDREDIRECTS: u32 = 2; +pub const IPCTL_DEFTTL: u32 = 3; +pub const IPCTL_SOURCEROUTE: u32 = 5; +pub const IPCTL_DIRECTEDBCAST: u32 = 6; +pub const IPCTL_IPPORT_FIRSTAUTO: u32 = 7; +pub const IPCTL_IPPORT_LASTAUTO: u32 = 8; +pub const IPCTL_IPPORT_HIFIRSTAUTO: u32 = 9; +pub const IPCTL_IPPORT_HILASTAUTO: u32 = 10; +pub const IPCTL_IPPORT_MAXQUEUE: u32 = 11; +pub const IPCTL_ENCDEBUG: u32 = 12; +pub const IPCTL_IPSEC_STATS: u32 = 13; +pub const IPCTL_IPSEC_EXPIRE_ACQUIRE: u32 = 14; +pub const IPCTL_IPSEC_EMBRYONIC_SA_TIMEOUT: u32 = 15; +pub const IPCTL_IPSEC_REQUIRE_PFS: u32 = 16; +pub const IPCTL_IPSEC_SOFT_ALLOCATIONS: u32 = 17; +pub const IPCTL_IPSEC_ALLOCATIONS: u32 = 18; +pub const IPCTL_IPSEC_SOFT_BYTES: u32 = 19; +pub const IPCTL_IPSEC_BYTES: u32 = 20; +pub const IPCTL_IPSEC_TIMEOUT: u32 = 21; +pub const IPCTL_IPSEC_SOFT_TIMEOUT: u32 = 22; +pub const IPCTL_IPSEC_SOFT_FIRSTUSE: u32 = 23; +pub const IPCTL_IPSEC_FIRSTUSE: u32 = 24; +pub const IPCTL_IPSEC_ENC_ALGORITHM: u32 = 25; +pub const IPCTL_IPSEC_AUTH_ALGORITHM: u32 = 26; +pub const IPCTL_MTUDISC: u32 = 27; +pub const IPCTL_MTUDISCTIMEOUT: u32 = 28; +pub const IPCTL_IPSEC_IPCOMP_ALGORITHM: u32 = 29; +pub const IPCTL_IFQUEUE: u32 = 30; +pub const IPCTL_MFORWARDING: u32 = 31; +pub const IPCTL_MULTIPATH: u32 = 32; +pub const IPCTL_STATS: u32 = 33; +pub const IPCTL_MRTPROTO: u32 = 34; +pub const IPCTL_MRTSTATS: u32 = 35; +pub const IPCTL_ARPQUEUED: u32 = 36; +pub const IPCTL_MRTMFC: u32 = 37; +pub const IPCTL_MRTVIF: u32 = 38; +pub const IPCTL_ARPTIMEOUT: u32 = 39; +pub const IPCTL_ARPDOWN: u32 = 40; +pub const IPCTL_ARPQUEUE: u32 = 41; +pub const IPCTL_MAXID: u32 = 42; +pub const INET6_ADDRSTRLEN: u32 = 46; +pub const __IPV6_ADDR_SCOPE_NODELOCAL: u32 = 1; +pub const __IPV6_ADDR_SCOPE_INTFACELOCAL: u32 = 1; +pub const __IPV6_ADDR_SCOPE_LINKLOCAL: u32 = 2; +pub const __IPV6_ADDR_SCOPE_SITELOCAL: u32 = 5; +pub const __IPV6_ADDR_SCOPE_ORGLOCAL: u32 = 8; +pub const __IPV6_ADDR_SCOPE_GLOBAL: u32 = 14; +pub const IPV6_UNICAST_HOPS: u32 = 4; +pub const IPV6_MULTICAST_IF: u32 = 9; +pub const IPV6_MULTICAST_HOPS: u32 = 10; +pub const IPV6_MULTICAST_LOOP: u32 = 11; +pub const IPV6_JOIN_GROUP: u32 = 12; +pub const IPV6_LEAVE_GROUP: u32 = 13; +pub const IPV6_PORTRANGE: u32 = 14; +pub const ICMP6_FILTER: u32 = 18; +pub const IPV6_CHECKSUM: u32 = 26; +pub const IPV6_V6ONLY: u32 = 27; +pub const IPV6_RTHDRDSTOPTS: u32 = 35; +pub const IPV6_RECVPKTINFO: u32 = 36; +pub const IPV6_RECVHOPLIMIT: u32 = 37; +pub const IPV6_RECVRTHDR: u32 = 38; +pub const IPV6_RECVHOPOPTS: u32 = 39; +pub const IPV6_RECVDSTOPTS: u32 = 40; +pub const IPV6_USE_MIN_MTU: u32 = 42; +pub const IPV6_RECVPATHMTU: u32 = 43; +pub const IPV6_PATHMTU: u32 = 44; +pub const IPV6_PKTINFO: u32 = 46; +pub const IPV6_HOPLIMIT: u32 = 47; +pub const IPV6_NEXTHOP: u32 = 48; +pub const IPV6_HOPOPTS: u32 = 49; +pub const IPV6_DSTOPTS: u32 = 50; +pub const IPV6_RTHDR: u32 = 51; +pub const IPV6_AUTH_LEVEL: u32 = 53; +pub const IPV6_ESP_TRANS_LEVEL: u32 = 54; +pub const IPV6_ESP_NETWORK_LEVEL: u32 = 55; +pub const IPSEC6_OUTSA: u32 = 56; +pub const IPV6_RECVTCLASS: u32 = 57; +pub const IPV6_AUTOFLOWLABEL: u32 = 59; +pub const IPV6_IPCOMP_LEVEL: u32 = 60; +pub const IPV6_TCLASS: u32 = 61; +pub const IPV6_DONTFRAG: u32 = 62; +pub const IPV6_PIPEX: u32 = 63; +pub const IPV6_RECVDSTPORT: u32 = 64; +pub const IPV6_MINHOPCOUNT: u32 = 65; +pub const IPV6_RTABLE: u32 = 4129; +pub const IPV6_RTHDR_LOOSE: u32 = 0; +pub const IPV6_RTHDR_TYPE_0: u32 = 0; +pub const IPV6_DEFAULT_MULTICAST_HOPS: u32 = 1; +pub const IPV6_DEFAULT_MULTICAST_LOOP: u32 = 1; +pub const IPV6_PORTRANGE_DEFAULT: u32 = 0; +pub const IPV6_PORTRANGE_HIGH: u32 = 1; +pub const IPV6_PORTRANGE_LOW: u32 = 2; +pub const IPV6PROTO_MAXID: u32 = 259; +pub const IPV6CTL_FORWARDING: u32 = 1; +pub const IPV6CTL_SENDREDIRECTS: u32 = 2; +pub const IPV6CTL_DEFHLIM: u32 = 3; +pub const IPV6CTL_FORWSRCRT: u32 = 5; +pub const IPV6CTL_STATS: u32 = 6; +pub const IPV6CTL_MRTSTATS: u32 = 7; +pub const IPV6CTL_MRTPROTO: u32 = 8; +pub const IPV6CTL_MAXFRAGPACKETS: u32 = 9; +pub const IPV6CTL_SOURCECHECK: u32 = 10; +pub const IPV6CTL_SOURCECHECK_LOGINT: u32 = 11; +pub const IPV6CTL_ACCEPT_RTADV: u32 = 12; +pub const IPV6CTL_LOG_INTERVAL: u32 = 14; +pub const IPV6CTL_HDRNESTLIMIT: u32 = 15; +pub const IPV6CTL_DAD_COUNT: u32 = 16; +pub const IPV6CTL_AUTO_FLOWLABEL: u32 = 17; +pub const IPV6CTL_DEFMCASTHLIM: u32 = 18; +pub const IPV6CTL_USE_DEPRECATED: u32 = 21; +pub const IPV6CTL_MAXFRAGS: u32 = 41; +pub const IPV6CTL_MFORWARDING: u32 = 42; +pub const IPV6CTL_MULTIPATH: u32 = 43; +pub const IPV6CTL_MCAST_PMTU: u32 = 44; +pub const IPV6CTL_NEIGHBORGCTHRESH: u32 = 45; +pub const IPV6CTL_MAXDYNROUTES: u32 = 48; +pub const IPV6CTL_DAD_PENDING: u32 = 49; +pub const IPV6CTL_MTUDISCTIMEOUT: u32 = 50; +pub const IPV6CTL_IFQUEUE: u32 = 51; +pub const IPV6CTL_MRTMIF: u32 = 52; +pub const IPV6CTL_MRTMFC: u32 = 53; +pub const IPV6CTL_SOIIKEY: u32 = 54; +pub const IPV6CTL_MAXID: u32 = 55; +pub const RNF_NORMAL: u32 = 1; +pub const RNF_ROOT: u32 = 2; +pub const RNF_ACTIVE: u32 = 4; +pub const RTF_UP: u32 = 1; +pub const RTF_GATEWAY: u32 = 2; +pub const RTF_HOST: u32 = 4; +pub const RTF_REJECT: u32 = 8; +pub const RTF_DYNAMIC: u32 = 16; +pub const RTF_MODIFIED: u32 = 32; +pub const RTF_DONE: u32 = 64; +pub const RTF_CLONING: u32 = 256; +pub const RTF_MULTICAST: u32 = 512; +pub const RTF_LLINFO: u32 = 1024; +pub const RTF_STATIC: u32 = 2048; +pub const RTF_BLACKHOLE: u32 = 4096; +pub const RTF_PROTO3: u32 = 8192; +pub const RTF_PROTO2: u32 = 16384; +pub const RTF_ANNOUNCE: u32 = 16384; +pub const RTF_PROTO1: u32 = 32768; +pub const RTF_CLONED: u32 = 65536; +pub const RTF_CACHED: u32 = 131072; +pub const RTF_MPATH: u32 = 262144; +pub const RTF_MPLS: u32 = 1048576; +pub const RTF_LOCAL: u32 = 2097152; +pub const RTF_BROADCAST: u32 = 4194304; +pub const RTF_CONNECTED: u32 = 8388608; +pub const RTF_BFD: u32 = 16777216; +pub const RTF_FMASK: u32 = 17890312; +pub const RTP_NONE: u32 = 0; +pub const RTP_LOCAL: u32 = 1; +pub const RTP_CONNECTED: u32 = 4; +pub const RTP_STATIC: u32 = 8; +pub const RTP_EIGRP: u32 = 28; +pub const RTP_OSPF: u32 = 32; +pub const RTP_ISIS: u32 = 36; +pub const RTP_RIP: u32 = 40; +pub const RTP_BGP: u32 = 48; +pub const RTP_DEFAULT: u32 = 56; +pub const RTP_PROPOSAL_STATIC: u32 = 57; +pub const RTP_PROPOSAL_DHCLIENT: u32 = 58; +pub const RTP_PROPOSAL_SLAAC: u32 = 59; +pub const RTP_PROPOSAL_UMB: u32 = 60; +pub const RTP_PROPOSAL_PPP: u32 = 61; +pub const RTP_PROPOSAL_SOLICIT: u32 = 62; +pub const RTP_MAX: u32 = 63; +pub const RTP_ANY: u32 = 64; +pub const RTP_MASK: u32 = 127; +pub const RTP_DOWN: u32 = 128; +pub const RTM_VERSION: u32 = 5; +pub const RTM_MAXSIZE: u32 = 2048; +pub const RTM_ADD: u32 = 1; +pub const RTM_DELETE: u32 = 2; +pub const RTM_CHANGE: u32 = 3; +pub const RTM_GET: u32 = 4; +pub const RTM_LOSING: u32 = 5; +pub const RTM_REDIRECT: u32 = 6; +pub const RTM_MISS: u32 = 7; +pub const RTM_RESOLVE: u32 = 11; +pub const RTM_NEWADDR: u32 = 12; +pub const RTM_DELADDR: u32 = 13; +pub const RTM_IFINFO: u32 = 14; +pub const RTM_IFANNOUNCE: u32 = 15; +pub const RTM_DESYNC: u32 = 16; +pub const RTM_INVALIDATE: u32 = 17; +pub const RTM_BFD: u32 = 18; +pub const RTM_PROPOSAL: u32 = 19; +pub const RTM_CHGADDRATTR: u32 = 20; +pub const RTM_80211INFO: u32 = 21; +pub const RTM_SOURCE: u32 = 22; +pub const RTV_MTU: u32 = 1; +pub const RTV_HOPCOUNT: u32 = 2; +pub const RTV_EXPIRE: u32 = 4; +pub const RTV_RPIPE: u32 = 8; +pub const RTV_SPIPE: u32 = 16; +pub const RTV_SSTHRESH: u32 = 32; +pub const RTV_RTT: u32 = 64; +pub const RTV_RTTVAR: u32 = 128; +pub const RTA_DST: u32 = 1; +pub const RTA_GATEWAY: u32 = 2; +pub const RTA_NETMASK: u32 = 4; +pub const RTA_GENMASK: u32 = 8; +pub const RTA_IFP: u32 = 16; +pub const RTA_IFA: u32 = 32; +pub const RTA_AUTHOR: u32 = 64; +pub const RTA_BRD: u32 = 128; +pub const RTA_SRC: u32 = 256; +pub const RTA_SRCMASK: u32 = 512; +pub const RTA_LABEL: u32 = 1024; +pub const RTA_BFD: u32 = 2048; +pub const RTA_DNS: u32 = 4096; +pub const RTA_STATIC: u32 = 8192; +pub const RTA_SEARCH: u32 = 16384; +pub const RTAX_DST: u32 = 0; +pub const RTAX_GATEWAY: u32 = 1; +pub const RTAX_NETMASK: u32 = 2; +pub const RTAX_GENMASK: u32 = 3; +pub const RTAX_IFP: u32 = 4; +pub const RTAX_IFA: u32 = 5; +pub const RTAX_AUTHOR: u32 = 6; +pub const RTAX_BRD: u32 = 7; +pub const RTAX_SRC: u32 = 8; +pub const RTAX_SRCMASK: u32 = 9; +pub const RTAX_LABEL: u32 = 10; +pub const RTAX_BFD: u32 = 11; +pub const RTAX_DNS: u32 = 12; +pub const RTAX_STATIC: u32 = 13; +pub const RTAX_SEARCH: u32 = 14; +pub const RTAX_MAX: u32 = 15; +pub const ROUTE_MSGFILTER: u32 = 1; +pub const ROUTE_TABLEFILTER: u32 = 2; +pub const ROUTE_PRIOFILTER: u32 = 3; +pub const ROUTE_FLAGFILTER: u32 = 4; +pub const RTABLE_ANY: u32 = 4294967295; +pub const RTLABEL_LEN: u32 = 32; +pub const RTDNS_LEN: u32 = 128; +pub const RTSTATIC_LEN: u32 = 128; +pub const RTSEARCH_LEN: u32 = 128; +pub const PF_MD5_DIGEST_LENGTH: u32 = 16; +pub const PFTM_TCP_FIRST_PACKET_VAL: u32 = 120; +pub const PFTM_TCP_OPENING_VAL: u32 = 30; +pub const PFTM_TCP_ESTABLISHED_VAL: u32 = 86400; +pub const PFTM_TCP_CLOSING_VAL: u32 = 900; +pub const PFTM_TCP_FIN_WAIT_VAL: u32 = 45; +pub const PFTM_TCP_CLOSED_VAL: u32 = 90; +pub const PFTM_UDP_FIRST_PACKET_VAL: u32 = 60; +pub const PFTM_UDP_SINGLE_VAL: u32 = 30; +pub const PFTM_UDP_MULTIPLE_VAL: u32 = 60; +pub const PFTM_ICMP_FIRST_PACKET_VAL: u32 = 20; +pub const PFTM_ICMP_ERROR_REPLY_VAL: u32 = 10; +pub const PFTM_OTHER_FIRST_PACKET_VAL: u32 = 60; +pub const PFTM_OTHER_SINGLE_VAL: u32 = 30; +pub const PFTM_OTHER_MULTIPLE_VAL: u32 = 60; +pub const PFTM_FRAG_VAL: u32 = 60; +pub const PFTM_INTERVAL_VAL: u32 = 10; +pub const PFTM_SRC_NODE_VAL: u32 = 0; +pub const PFTM_TS_DIFF_VAL: u32 = 30; +pub const PF_FRAG_STALE: u32 = 200; +pub const PF_FRAG_ENTRY_POINTS: u32 = 16; +pub const PF_FRAG_ENTRY_LIMIT: u32 = 64; +pub const PF_POOL_IDMASK: u32 = 15; +pub const PF_POOL_TYPEMASK: u32 = 15; +pub const PF_POOL_STICKYADDR: u32 = 32; +pub const PF_WSCALE_FLAG: u32 = 128; +pub const PF_WSCALE_MASK: u32 = 15; +pub const PF_LOG: u32 = 1; +pub const PF_LOG_ALL: u32 = 2; +pub const PF_LOG_USER: u32 = 4; +pub const PF_LOG_FORCE: u32 = 8; +pub const PF_LOG_MATCHES: u32 = 16; +pub const PF_TABLE_NAME_SIZE: u32 = 32; +pub const PFI_AFLAG_NETWORK: u32 = 1; +pub const PFI_AFLAG_BROADCAST: u32 = 2; +pub const PFI_AFLAG_PEER: u32 = 4; +pub const PFI_AFLAG_MODEMASK: u32 = 7; +pub const PFI_AFLAG_NOALIAS: u32 = 8; +pub const PF_DEBUGNAME: &[u8; 5] = b"pf: \0"; +pub const PF_THRESHOLD_MULT: u32 = 1000; +pub const PF_THRESHOLD_MAX: u32 = 4294967; +pub const PF_OSFP_EXPANDED: u32 = 1; +pub const PF_OSFP_GENERIC: u32 = 2; +pub const PF_OSFP_NODETAIL: u32 = 4; +pub const PF_OSFP_LEN: u32 = 32; +pub const _FP_RESERVED_BIT: u32 = 1; +pub const _FP_UNUSED_BITS: u32 = 1; +pub const _FP_CLASS_BITS: u32 = 10; +pub const _FP_VERSION_BITS: u32 = 10; +pub const _FP_SUBTYPE_BITS: u32 = 10; +pub const PF_OSFP_WSIZE_MOD: u32 = 1; +pub const PF_OSFP_WSIZE_DC: u32 = 2; +pub const PF_OSFP_WSIZE_MSS: u32 = 4; +pub const PF_OSFP_WSIZE_MTU: u32 = 8; +pub const PF_OSFP_PSIZE_MOD: u32 = 16; +pub const PF_OSFP_PSIZE_DC: u32 = 32; +pub const PF_OSFP_WSCALE: u32 = 64; +pub const PF_OSFP_WSCALE_MOD: u32 = 128; +pub const PF_OSFP_WSCALE_DC: u32 = 256; +pub const PF_OSFP_MSS: u32 = 512; +pub const PF_OSFP_MSS_MOD: u32 = 1024; +pub const PF_OSFP_MSS_DC: u32 = 2048; +pub const PF_OSFP_DF: u32 = 4096; +pub const PF_OSFP_TS0: u32 = 8192; +pub const PF_OSFP_INET6: u32 = 16384; +pub const PF_OSFP_MAXTTL_OFFSET: u32 = 40; +pub const PF_OSFP_TCPOPT_NOP: u32 = 0; +pub const PF_OSFP_TCPOPT_WSCALE: u32 = 1; +pub const PF_OSFP_TCPOPT_MSS: u32 = 2; +pub const PF_OSFP_TCPOPT_SACK: u32 = 3; +pub const PF_OSFP_TCPOPT_TS: u32 = 4; +pub const PF_OSFP_TCPOPT_BITS: u32 = 3; +pub const PF_ANCHOR_STACK_MAX: u32 = 64; +pub const PF_ANCHOR_NAME_SIZE: u32 = 64; +pub const PF_ANCHOR_MAXPATH: u32 = 959; +pub const PF_ANCHOR_HIWAT: u32 = 512; +pub const PF_OPTIMIZER_TABLE_PFX: &[u8; 13] = b"__automatic_\0"; +pub const PF_SKIP_IFP: u32 = 0; +pub const PF_SKIP_DIR: u32 = 1; +pub const PF_SKIP_RDOM: u32 = 2; +pub const PF_SKIP_AF: u32 = 3; +pub const PF_SKIP_PROTO: u32 = 4; +pub const PF_SKIP_SRC_ADDR: u32 = 5; +pub const PF_SKIP_DST_ADDR: u32 = 6; +pub const PF_SKIP_SRC_PORT: u32 = 7; +pub const PF_SKIP_DST_PORT: u32 = 8; +pub const PF_SKIP_COUNT: u32 = 9; +pub const PF_RULE_LABEL_SIZE: u32 = 64; +pub const PF_QNAME_SIZE: u32 = 64; +pub const PF_TAG_NAME_SIZE: u32 = 64; +pub const PF_STATE_NORMAL: u32 = 1; +pub const PF_STATE_MODULATE: u32 = 2; +pub const PF_STATE_SYNPROXY: u32 = 3; +pub const PF_FLUSH: u32 = 1; +pub const PF_FLUSH_GLOBAL: u32 = 2; +pub const PFRULE_DROP: u32 = 0; +pub const PFRULE_RETURNRST: u32 = 1; +pub const PFRULE_FRAGMENT: u32 = 2; +pub const PFRULE_RETURNICMP: u32 = 4; +pub const PFRULE_RETURN: u32 = 8; +pub const PFRULE_NOSYNC: u32 = 16; +pub const PFRULE_SRCTRACK: u32 = 32; +pub const PFRULE_RULESRCTRACK: u32 = 64; +pub const PFRULE_SETDELAY: u32 = 128; +pub const PFRULE_IFBOUND: u32 = 65536; +pub const PFRULE_STATESLOPPY: u32 = 131072; +pub const PFRULE_PFLOW: u32 = 262144; +pub const PFRULE_ONCE: u32 = 1048576; +pub const PFRULE_AFTO: u32 = 2097152; +pub const PFRULE_EXPIRED: u32 = 4194304; +pub const PFSTATE_HIWAT: u32 = 100000; +pub const PFSTATE_ADAPT_START: u32 = 60000; +pub const PFSTATE_ADAPT_END: u32 = 120000; +pub const PF_PKTDELAY_MAXPKTS: u32 = 10000; +pub const PFSNODE_HIWAT: u32 = 10000; +pub const PFSS_TIMESTAMP: u32 = 1; +pub const PFSS_PAWS: u32 = 16; +pub const PFSS_PAWS_IDLED: u32 = 32; +pub const PFSS_DATA_TS: u32 = 64; +pub const PFSS_DATA_NOTS: u32 = 128; +pub const PFSTATE_ALLOWOPTS: u32 = 1; +pub const PFSTATE_SLOPPY: u32 = 2; +pub const PFSTATE_PFLOW: u32 = 4; +pub const PFSTATE_NOSYNC: u32 = 8; +pub const PFSTATE_ACK: u32 = 16; +pub const PFSTATE_NODF: u32 = 32; +pub const PFSTATE_SETTOS: u32 = 64; +pub const PFSTATE_RANDOMID: u32 = 128; +pub const PFSTATE_SCRUB_TCP: u32 = 256; +pub const PFSTATE_SETPRIO: u32 = 512; +pub const PFSTATE_INP_UNLINKED: u32 = 1024; +pub const PFSTATE_SCRUBMASK: u32 = 416; +pub const PFSTATE_SETMASK: u32 = 576; +pub const PFSYNC_SCRUB_FLAG_VALID: u32 = 1; +pub const PFSYNC_FLAG_SRCNODE: u32 = 4; +pub const PFSYNC_FLAG_NATSRCNODE: u32 = 8; +pub const PF_RESERVED_ANCHOR: &[u8; 4] = b"_pf\0"; +pub const PFR_TFLAG_PERSIST: u32 = 1; +pub const PFR_TFLAG_CONST: u32 = 2; +pub const PFR_TFLAG_ACTIVE: u32 = 4; +pub const PFR_TFLAG_INACTIVE: u32 = 8; +pub const PFR_TFLAG_REFERENCED: u32 = 16; +pub const PFR_TFLAG_REFDANCHOR: u32 = 32; +pub const PFR_TFLAG_COUNTERS: u32 = 64; +pub const PFR_TFLAG_USRMASK: u32 = 67; +pub const PFR_TFLAG_SETMASK: u32 = 60; +pub const PFR_TFLAG_ALLMASK: u32 = 127; +pub const PFRKE_FLAG_NOT: u32 = 1; +pub const PFRKE_FLAG_MARK: u32 = 2; +pub const PFI_IFLAG_SKIP: u32 = 256; +pub const PFI_IFLAG_ANY: u32 = 512; +pub const PF_DPORT_RANGE: u32 = 1; +pub const PF_RPORT_RANGE: u32 = 2; +pub const PFRES_MATCH: u32 = 0; +pub const PFRES_BADOFF: u32 = 1; +pub const PFRES_FRAG: u32 = 2; +pub const PFRES_SHORT: u32 = 3; +pub const PFRES_NORM: u32 = 4; +pub const PFRES_MEMORY: u32 = 5; +pub const PFRES_TS: u32 = 6; +pub const PFRES_CONGEST: u32 = 7; +pub const PFRES_IPOPTIONS: u32 = 8; +pub const PFRES_PROTCKSUM: u32 = 9; +pub const PFRES_BADSTATE: u32 = 10; +pub const PFRES_STATEINS: u32 = 11; +pub const PFRES_MAXSTATES: u32 = 12; +pub const PFRES_SRCLIMIT: u32 = 13; +pub const PFRES_SYNPROXY: u32 = 14; +pub const PFRES_TRANSLATE: u32 = 15; +pub const PFRES_NOROUTE: u32 = 16; +pub const PFRES_MAX: u32 = 17; +pub const LCNT_STATES: u32 = 0; +pub const LCNT_SRCSTATES: u32 = 1; +pub const LCNT_SRCNODES: u32 = 2; +pub const LCNT_SRCCONN: u32 = 3; +pub const LCNT_SRCCONNRATE: u32 = 4; +pub const LCNT_OVERLOAD_TABLE: u32 = 5; +pub const LCNT_OVERLOAD_FLUSH: u32 = 6; +pub const LCNT_SYNFLOODS: u32 = 7; +pub const LCNT_SYNCOOKIES_SENT: u32 = 8; +pub const LCNT_SYNCOOKIES_VALID: u32 = 9; +pub const LCNT_MAX: u32 = 10; +pub const PFUDPS_NO_TRAFFIC: u32 = 0; +pub const PFUDPS_SINGLE: u32 = 1; +pub const PFUDPS_MULTIPLE: u32 = 2; +pub const PFUDPS_NSTATES: u32 = 3; +pub const PFOTHERS_NO_TRAFFIC: u32 = 0; +pub const PFOTHERS_SINGLE: u32 = 1; +pub const PFOTHERS_MULTIPLE: u32 = 2; +pub const PFOTHERS_NSTATES: u32 = 3; +pub const FCNT_STATE_SEARCH: u32 = 0; +pub const FCNT_STATE_INSERT: u32 = 1; +pub const FCNT_STATE_REMOVALS: u32 = 2; +pub const FCNT_MAX: u32 = 3; +pub const SCNT_SRC_NODE_SEARCH: u32 = 0; +pub const SCNT_SRC_NODE_INSERT: u32 = 1; +pub const SCNT_SRC_NODE_REMOVALS: u32 = 2; +pub const SCNT_MAX: u32 = 3; +pub const PF_REASS_ENABLED: u32 = 1; +pub const PF_REASS_NODF: u32 = 2; +pub const PF_SYNCOOKIES_NEVER: u32 = 0; +pub const PF_SYNCOOKIES_ALWAYS: u32 = 1; +pub const PF_SYNCOOKIES_ADAPTIVE: u32 = 2; +pub const PF_SYNCOOKIES_MODE_MAX: u32 = 2; +pub const PF_SYNCOOKIES_HIWATPCT: u32 = 25; +pub const PF_SYNCOOKIES_LOWATPCT: u32 = 12; +pub const PF_PRIO_ZERO: u32 = 255; +pub const PFQS_FLOWQUEUE: u32 = 1; +pub const PFQS_ROOTCLASS: u32 = 2; +pub const PFQS_DEFAULT: u32 = 4096; +pub const PFR_KTABLE_HIWAT: u32 = 1000; +pub const PFR_KENTRY_HIWAT: u32 = 200000; +pub const PFR_KENTRY_HIWAT_SMALL: u32 = 100000; +pub const PFR_FLAG_DUMMY: u32 = 2; +pub const PFR_FLAG_FEEDBACK: u32 = 4; +pub const PFR_FLAG_CLSTATS: u32 = 8; +pub const PFR_FLAG_ADDRSTOO: u32 = 16; +pub const PFR_FLAG_REPLACE: u32 = 32; +pub const PFR_FLAG_ALLRSETS: u32 = 64; +pub const PFR_FLAG_ALLMASK: u32 = 127; +pub type __int8_t = ::std::os::raw::c_schar; +pub type __uint8_t = ::std::os::raw::c_uchar; +pub type __int16_t = ::std::os::raw::c_short; +pub type __uint16_t = ::std::os::raw::c_ushort; +pub type __int32_t = ::std::os::raw::c_int; +pub type __uint32_t = ::std::os::raw::c_uint; +pub type __int64_t = ::std::os::raw::c_longlong; +pub type __uint64_t = ::std::os::raw::c_ulonglong; +pub type __int_least8_t = __int8_t; +pub type __uint_least8_t = __uint8_t; +pub type __int_least16_t = __int16_t; +pub type __uint_least16_t = __uint16_t; +pub type __int_least32_t = __int32_t; +pub type __uint_least32_t = __uint32_t; +pub type __int_least64_t = __int64_t; +pub type __uint_least64_t = __uint64_t; +pub type __int_fast8_t = __int32_t; +pub type __uint_fast8_t = __uint32_t; +pub type __int_fast16_t = __int32_t; +pub type __uint_fast16_t = __uint32_t; +pub type __int_fast32_t = __int32_t; +pub type __uint_fast32_t = __uint32_t; +pub type __int_fast64_t = __int64_t; +pub type __uint_fast64_t = __uint64_t; +pub type __intptr_t = ::std::os::raw::c_long; +pub type __uintptr_t = ::std::os::raw::c_ulong; +pub type __intmax_t = __int64_t; +pub type __uintmax_t = __uint64_t; +pub type __register_t = ::std::os::raw::c_long; +pub type __vaddr_t = ::std::os::raw::c_ulong; +pub type __paddr_t = ::std::os::raw::c_ulong; +pub type __vsize_t = ::std::os::raw::c_ulong; +pub type __psize_t = ::std::os::raw::c_ulong; +pub type __double_t = f64; +pub type __float_t = f32; +pub type __ptrdiff_t = ::std::os::raw::c_long; +pub type __size_t = ::std::os::raw::c_ulong; +pub type __ssize_t = ::std::os::raw::c_long; +pub type __va_list = __builtin_va_list; +pub type __wchar_t = ::std::os::raw::c_int; +pub type __wint_t = ::std::os::raw::c_int; +pub type __rune_t = ::std::os::raw::c_int; +pub type __wctrans_t = *mut ::std::os::raw::c_void; +pub type __wctype_t = *mut ::std::os::raw::c_void; +pub type int_least8_t = __int_least8_t; +pub type uint_least8_t = __uint_least8_t; +pub type int_least16_t = __int_least16_t; +pub type uint_least16_t = __uint_least16_t; +pub type int_least32_t = __int_least32_t; +pub type uint_least32_t = __uint_least32_t; +pub type int_least64_t = __int_least64_t; +pub type uint_least64_t = __uint_least64_t; +pub type int_fast8_t = __int_fast8_t; +pub type uint_fast8_t = __uint_fast8_t; +pub type int_fast16_t = __int_fast16_t; +pub type uint_fast16_t = __uint_fast16_t; +pub type int_fast32_t = __int_fast32_t; +pub type uint_fast32_t = __uint_fast32_t; +pub type int_fast64_t = __int_fast64_t; +pub type uint_fast64_t = __uint_fast64_t; +pub type intmax_t = __intmax_t; +pub type uintmax_t = __uintmax_t; +pub type __blkcnt_t = __int64_t; +pub type __blksize_t = __int32_t; +pub type __clock_t = __int64_t; +pub type __clockid_t = __int32_t; +pub type __cpuid_t = ::std::os::raw::c_ulong; +pub type __dev_t = __int32_t; +pub type __fixpt_t = __uint32_t; +pub type __fsblkcnt_t = __uint64_t; +pub type __fsfilcnt_t = __uint64_t; +pub type __gid_t = __uint32_t; +pub type __id_t = __uint32_t; +pub type __in_addr_t = __uint32_t; +pub type __in_port_t = __uint16_t; +pub type __ino_t = __uint64_t; +pub type __key_t = ::std::os::raw::c_long; +pub type __mode_t = __uint32_t; +pub type __nlink_t = __uint32_t; +pub type __off_t = __int64_t; +pub type __pid_t = __int32_t; +pub type __rlim_t = __uint64_t; +pub type __sa_family_t = __uint8_t; +pub type __segsz_t = __int32_t; +pub type __socklen_t = __uint32_t; +pub type __suseconds_t = ::std::os::raw::c_long; +pub type __time_t = __int64_t; +pub type __timer_t = __int32_t; +pub type __uid_t = __uint32_t; +pub type __useconds_t = __uint32_t; +#[repr(C)] +#[derive(Copy, Clone)] +pub union __mbstate_t { + pub __mbstate8: [::std::os::raw::c_char; 128usize], + pub __mbstateL: __int64_t, +} +#[test] +fn bindgen_test_layout___mbstate_t() { + const UNINIT: ::std::mem::MaybeUninit<__mbstate_t> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__mbstate_t>(), + 128usize, + concat!("Size of: ", stringify!(__mbstate_t)) + ); + assert_eq!( + ::std::mem::align_of::<__mbstate_t>(), + 8usize, + concat!("Alignment of ", stringify!(__mbstate_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__mbstate8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__mbstate_t), + "::", + stringify!(__mbstate8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__mbstateL) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__mbstate_t), + "::", + stringify!(__mbstateL) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct iovec { + pub iov_base: *mut ::std::os::raw::c_void, + pub iov_len: usize, +} +#[test] +fn bindgen_test_layout_iovec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(iovec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(iovec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iov_base) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(iovec), "::", stringify!(iov_base)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iov_len) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(iovec), "::", stringify!(iov_len)) + ); +} +pub const uio_rw_UIO_READ: uio_rw = 0; +pub const uio_rw_UIO_WRITE: uio_rw = 1; +pub type uio_rw = ::std::os::raw::c_uint; +pub const uio_seg_UIO_USERSPACE: uio_seg = 0; +pub const uio_seg_UIO_SYSSPACE: uio_seg = 1; +pub type uio_seg = ::std::os::raw::c_uint; +extern "C" { + pub fn preadv(arg1: ::std::os::raw::c_int, arg2: *const iovec, arg3: ::std::os::raw::c_int, arg4: __off_t) + -> isize; +} +extern "C" { + pub fn pwritev( + arg1: ::std::os::raw::c_int, + arg2: *const iovec, + arg3: ::std::os::raw::c_int, + arg4: __off_t, + ) -> isize; +} +extern "C" { + pub fn readv(arg1: ::std::os::raw::c_int, arg2: *const iovec, arg3: ::std::os::raw::c_int) -> isize; +} +extern "C" { + pub fn writev(arg1: ::std::os::raw::c_int, arg2: *const iovec, arg3: ::std::os::raw::c_int) -> isize; +} +pub type u_char = ::std::os::raw::c_uchar; +pub type u_short = ::std::os::raw::c_ushort; +pub type u_int = ::std::os::raw::c_uint; +pub type u_long = ::std::os::raw::c_ulong; +pub type unchar = ::std::os::raw::c_uchar; +pub type ushort = ::std::os::raw::c_ushort; +pub type uint = ::std::os::raw::c_uint; +pub type ulong = ::std::os::raw::c_ulong; +pub type cpuid_t = __cpuid_t; +pub type register_t = __register_t; +pub type u_int8_t = __uint8_t; +pub type u_int16_t = __uint16_t; +pub type u_int32_t = __uint32_t; +pub type u_int64_t = __uint64_t; +pub type quad_t = __int64_t; +pub type u_quad_t = __uint64_t; +pub type vaddr_t = __vaddr_t; +pub type paddr_t = __paddr_t; +pub type vsize_t = __vsize_t; +pub type psize_t = __psize_t; +pub type blkcnt_t = __blkcnt_t; +pub type blksize_t = __blksize_t; +pub type caddr_t = *mut ::std::os::raw::c_char; +pub type daddr32_t = __int32_t; +pub type daddr_t = __int64_t; +pub type dev_t = __dev_t; +pub type fixpt_t = __fixpt_t; +pub type gid_t = __gid_t; +pub type id_t = __id_t; +pub type ino_t = __ino_t; +pub type key_t = __key_t; +pub type mode_t = __mode_t; +pub type nlink_t = __nlink_t; +pub type rlim_t = __rlim_t; +pub type segsz_t = __segsz_t; +pub type uid_t = __uid_t; +pub type useconds_t = __useconds_t; +pub type suseconds_t = __suseconds_t; +pub type fsblkcnt_t = __fsblkcnt_t; +pub type fsfilcnt_t = __fsfilcnt_t; +pub type clock_t = __clock_t; +pub type clockid_t = __clockid_t; +pub type pid_t = __pid_t; +pub type time_t = __time_t; +pub type timer_t = __timer_t; +pub type off_t = __off_t; +extern "C" { + pub fn lseek(arg1: ::std::os::raw::c_int, arg2: off_t, arg3: ::std::os::raw::c_int) -> off_t; +} +extern "C" { + pub fn ftruncate(arg1: ::std::os::raw::c_int, arg2: off_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn truncate(arg1: *const ::std::os::raw::c_char, arg2: off_t) -> ::std::os::raw::c_int; +} +pub type socklen_t = __socklen_t; +pub type sa_family_t = __sa_family_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct linger { + pub l_onoff: ::std::os::raw::c_int, + pub l_linger: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_linger() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(linger)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(linger)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).l_onoff) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(linger), "::", stringify!(l_onoff)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).l_linger) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(linger), "::", stringify!(l_linger)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timeval { + pub tv_sec: time_t, + pub tv_usec: suseconds_t, +} +#[test] +fn bindgen_test_layout_timeval() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timeval)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(timeval)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(timeval), "::", stringify!(tv_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_usec) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(timeval), "::", stringify!(tv_usec)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct splice { + pub sp_fd: ::std::os::raw::c_int, + pub sp_max: off_t, + pub sp_idle: timeval, +} +#[test] +fn bindgen_test_layout_splice() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(splice)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(splice)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sp_fd) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(splice), "::", stringify!(sp_fd)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sp_max) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(splice), "::", stringify!(sp_max)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sp_idle) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(splice), "::", stringify!(sp_idle)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr { + pub sa_len: __uint8_t, + pub sa_family: sa_family_t, + pub sa_data: [::std::os::raw::c_char; 14usize], +} +#[test] +fn bindgen_test_layout_sockaddr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sockaddr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(sockaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr), "::", stringify!(sa_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_family) as usize - ptr as usize }, + 1usize, + concat!("Offset of field: ", stringify!(sockaddr), "::", stringify!(sa_family)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa_data) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(sockaddr), "::", stringify!(sa_data)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_storage { + pub ss_len: __uint8_t, + pub ss_family: sa_family_t, + pub __ss_pad1: [::std::os::raw::c_uchar; 6usize], + pub __ss_pad2: __uint64_t, + pub __ss_pad3: [::std::os::raw::c_uchar; 240usize], +} +#[test] +fn bindgen_test_layout_sockaddr_storage() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 256usize, + concat!("Size of: ", stringify!(sockaddr_storage)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(sockaddr_storage)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(ss_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ss_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(ss_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss_pad1) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(__ss_pad1) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss_pad2) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(__ss_pad2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__ss_pad3) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_storage), + "::", + stringify!(__ss_pad3) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockpeercred { + pub uid: uid_t, + pub gid: gid_t, + pub pid: pid_t, +} +#[test] +fn bindgen_test_layout_sockpeercred() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(sockpeercred)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockpeercred)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockpeercred), "::", stringify!(uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gid) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(sockpeercred), "::", stringify!(gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pid) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sockpeercred), "::", stringify!(pid)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct msghdr { + pub msg_name: *mut ::std::os::raw::c_void, + pub msg_namelen: socklen_t, + pub msg_iov: *mut iovec, + pub msg_iovlen: ::std::os::raw::c_uint, + pub msg_control: *mut ::std::os::raw::c_void, + pub msg_controllen: socklen_t, + pub msg_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_namelen) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_namelen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iov) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_iov)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_iovlen) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_iovlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_control) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_control)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_controllen) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(msghdr), + "::", + stringify!(msg_controllen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_flags) as usize - ptr as usize }, + 44usize, + concat!("Offset of field: ", stringify!(msghdr), "::", stringify!(msg_flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct mmsghdr { + pub msg_hdr: msghdr, + pub msg_len: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_mmsghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(mmsghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(mmsghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_hdr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(mmsghdr), "::", stringify!(msg_hdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).msg_len) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(mmsghdr), "::", stringify!(msg_len)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct cmsghdr { + pub cmsg_len: socklen_t, + pub cmsg_level: ::std::os::raw::c_int, + pub cmsg_type: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_cmsghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(cmsghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(cmsghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmsg_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(cmsghdr), "::", stringify!(cmsg_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmsg_level) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(cmsghdr), "::", stringify!(cmsg_level)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cmsg_type) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(cmsghdr), "::", stringify!(cmsg_type)) + ); +} +extern "C" { + pub fn accept(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr, arg3: *mut socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn bind(arg1: ::std::os::raw::c_int, arg2: *const sockaddr, arg3: socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn connect(arg1: ::std::os::raw::c_int, arg2: *const sockaddr, arg3: socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getpeername(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr, arg3: *mut socklen_t) + -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsockname(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr, arg3: *mut socklen_t) + -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsockopt( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *mut ::std::os::raw::c_void, + arg5: *mut socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn listen(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn recv( + arg1: ::std::os::raw::c_int, + arg2: *mut ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + ) -> isize; +} +extern "C" { + pub fn recvfrom( + arg1: ::std::os::raw::c_int, + arg2: *mut ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + arg5: *mut sockaddr, + arg6: *mut socklen_t, + ) -> isize; +} +extern "C" { + pub fn recvmsg(arg1: ::std::os::raw::c_int, arg2: *mut msghdr, arg3: ::std::os::raw::c_int) -> isize; +} +extern "C" { + pub fn recvmmsg( + arg1: ::std::os::raw::c_int, + arg2: *mut mmsghdr, + arg3: ::std::os::raw::c_uint, + arg4: ::std::os::raw::c_int, + arg5: *mut timespec, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn send( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + ) -> isize; +} +extern "C" { + pub fn sendto( + arg1: ::std::os::raw::c_int, + arg2: *const ::std::os::raw::c_void, + arg3: usize, + arg4: ::std::os::raw::c_int, + arg5: *const sockaddr, + arg6: socklen_t, + ) -> isize; +} +extern "C" { + pub fn sendmsg(arg1: ::std::os::raw::c_int, arg2: *const msghdr, arg3: ::std::os::raw::c_int) -> isize; +} +extern "C" { + pub fn sendmmsg( + arg1: ::std::os::raw::c_int, + arg2: *mut mmsghdr, + arg3: ::std::os::raw::c_uint, + arg4: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setsockopt( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *const ::std::os::raw::c_void, + arg5: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn shutdown(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn sockatmark(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn socket( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn socketpair( + arg1: ::std::os::raw::c_int, + arg2: ::std::os::raw::c_int, + arg3: ::std::os::raw::c_int, + arg4: *mut ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn accept4( + arg1: ::std::os::raw::c_int, + arg2: *mut sockaddr, + arg3: *mut socklen_t, + arg4: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getpeereid(arg1: ::std::os::raw::c_int, arg2: *mut uid_t, arg3: *mut gid_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getrtable() -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setrtable(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_nameindex { + pub if_index: ::std::os::raw::c_uint, + pub if_name: *mut ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_if_nameindex() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_nameindex)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_nameindex)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_index) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_nameindex), + "::", + stringify!(if_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_name) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_nameindex), "::", stringify!(if_name)) + ); +} +extern "C" { + pub fn if_nametoindex(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_uint; +} +extern "C" { + pub fn if_indextoname( + arg1: ::std::os::raw::c_uint, + arg2: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn if_nameindex() -> *mut if_nameindex; +} +extern "C" { + pub fn if_freenameindex(arg1: *mut if_nameindex); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timespec { + pub tv_sec: time_t, + pub tv_nsec: ::std::os::raw::c_long, +} +#[test] +fn bindgen_test_layout_timespec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timespec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(timespec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(timespec), "::", stringify!(tv_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tv_nsec) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(timespec), "::", stringify!(tv_nsec)) + ); +} +pub type __fd_mask = u32; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct fd_set { + pub fds_bits: [__fd_mask; 32usize], +} +#[test] +fn bindgen_test_layout_fd_set() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(fd_set)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(fd_set)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fds_bits) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(fd_set), "::", stringify!(fds_bits)) + ); +} +pub type sigset_t = ::std::os::raw::c_uint; +extern "C" { + pub fn select( + arg1: ::std::os::raw::c_int, + arg2: *mut fd_set, + arg3: *mut fd_set, + arg4: *mut fd_set, + arg5: *mut timeval, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pselect( + arg1: ::std::os::raw::c_int, + arg2: *mut fd_set, + arg3: *mut fd_set, + arg4: *mut fd_set, + arg5: *const timespec, + arg6: *const sigset_t, + ) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timezone { + pub tz_minuteswest: ::std::os::raw::c_int, + pub tz_dsttime: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_timezone() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(timezone)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(timezone)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tz_minuteswest) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timezone), + "::", + stringify!(tz_minuteswest) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tz_dsttime) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(timezone), "::", stringify!(tz_dsttime)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct itimerval { + pub it_interval: timeval, + pub it_value: timeval, +} +#[test] +fn bindgen_test_layout_itimerval() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(itimerval)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(itimerval)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_interval) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(itimerval), + "::", + stringify!(it_interval) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_value) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(itimerval), "::", stringify!(it_value)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct clockinfo { + pub hz: ::std::os::raw::c_int, + pub tick: ::std::os::raw::c_int, + pub stathz: ::std::os::raw::c_int, + pub profhz: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_clockinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(clockinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(clockinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hz) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(hz)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tick) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(tick)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).stathz) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(stathz)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).profhz) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(clockinfo), "::", stringify!(profhz)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct itimerspec { + pub it_interval: timespec, + pub it_value: timespec, +} +#[test] +fn bindgen_test_layout_itimerspec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(itimerspec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(itimerspec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_interval) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(itimerspec), + "::", + stringify!(it_interval) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).it_value) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(itimerspec), "::", stringify!(it_value)) + ); +} +pub type locale_t = *mut ::std::os::raw::c_void; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct tm { + pub tm_sec: ::std::os::raw::c_int, + pub tm_min: ::std::os::raw::c_int, + pub tm_hour: ::std::os::raw::c_int, + pub tm_mday: ::std::os::raw::c_int, + pub tm_mon: ::std::os::raw::c_int, + pub tm_year: ::std::os::raw::c_int, + pub tm_wday: ::std::os::raw::c_int, + pub tm_yday: ::std::os::raw::c_int, + pub tm_isdst: ::std::os::raw::c_int, + pub tm_gmtoff: ::std::os::raw::c_long, + pub tm_zone: *mut ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_tm() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(tm)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(tm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_sec) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_sec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_min) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_min)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_hour) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_hour)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_mday) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_mday)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_mon) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_mon)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_year) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_year)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_wday) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_wday)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_yday) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_yday)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_isdst) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_isdst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_gmtoff) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_gmtoff)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tm_zone) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(tm), "::", stringify!(tm_zone)) + ); +} +extern "C" { + pub fn asctime(arg1: *const tm) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn clock() -> clock_t; +} +extern "C" { + pub fn ctime(arg1: *const time_t) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn difftime(arg1: time_t, arg2: time_t) -> f64; +} +extern "C" { + pub fn gmtime(arg1: *const time_t) -> *mut tm; +} +extern "C" { + pub fn localtime(arg1: *const time_t) -> *mut tm; +} +extern "C" { + pub fn mktime(arg1: *mut tm) -> time_t; +} +extern "C" { + pub fn strftime( + arg1: *mut ::std::os::raw::c_char, + arg2: usize, + arg3: *const ::std::os::raw::c_char, + arg4: *const tm, + ) -> usize; +} +extern "C" { + pub fn time(arg1: *mut time_t) -> time_t; +} +extern "C" { + pub static mut daylight: ::std::os::raw::c_int; +} +extern "C" { + pub static mut timezone: ::std::os::raw::c_long; +} +extern "C" { + pub fn strptime( + arg1: *const ::std::os::raw::c_char, + arg2: *const ::std::os::raw::c_char, + arg3: *mut tm, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn asctime_r(arg1: *const tm, arg2: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ctime_r(arg1: *const time_t, arg2: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn gmtime_r(arg1: *const time_t, arg2: *mut tm) -> *mut tm; +} +extern "C" { + pub fn localtime_r(arg1: *const time_t, arg2: *mut tm) -> *mut tm; +} +extern "C" { + pub static mut tzname: [*mut ::std::os::raw::c_char; 2usize]; +} +extern "C" { + pub fn tzset(); +} +extern "C" { + pub fn clock_getres(arg1: clockid_t, arg2: *mut timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_gettime(arg1: clockid_t, arg2: *mut timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_settime(arg1: clockid_t, arg2: *const timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn nanosleep(arg1: *const timespec, arg2: *mut timespec) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clock_getcpuclockid(arg1: pid_t, arg2: *mut clockid_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strftime_l( + arg1: *mut ::std::os::raw::c_char, + arg2: usize, + arg3: *const ::std::os::raw::c_char, + arg4: *const tm, + arg5: locale_t, + ) -> usize; +} +extern "C" { + pub fn timespec_get(_ts: *mut timespec, _base: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn tzsetwall(); +} +extern "C" { + pub fn timelocal(arg1: *mut tm) -> time_t; +} +extern "C" { + pub fn timegm(arg1: *mut tm) -> time_t; +} +extern "C" { + pub fn timeoff(arg1: *mut tm, arg2: ::std::os::raw::c_long) -> time_t; +} +extern "C" { + pub fn adjtime(arg1: *const timeval, arg2: *mut timeval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn adjfreq(arg1: *const i64, arg2: *mut i64) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn futimes(arg1: ::std::os::raw::c_int, arg2: *const timeval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getitimer(arg1: ::std::os::raw::c_int, arg2: *mut itimerval) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn gettimeofday(arg1: *mut timeval, arg2: *mut timezone) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setitimer( + arg1: ::std::os::raw::c_int, + arg2: *const itimerval, + arg3: *mut itimerval, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn settimeofday(arg1: *const timeval, arg2: *const timezone) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn utimes(arg1: *const ::std::os::raw::c_char, arg2: *const timeval) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_clonereq { + pub ifcr_total: ::std::os::raw::c_int, + pub ifcr_count: ::std::os::raw::c_int, + pub ifcr_buffer: *mut ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_if_clonereq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_clonereq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_clonereq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcr_total) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_clonereq), + "::", + stringify!(ifcr_total) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcr_count) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_clonereq), + "::", + stringify!(ifcr_count) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcr_buffer) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_clonereq), + "::", + stringify!(ifcr_buffer) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_rxring { + pub rxr_adjusted: ::std::os::raw::c_int, + pub rxr_alive: u_int, + pub rxr_cwm: u_int, + pub rxr_lwm: u_int, + pub rxr_hwm: u_int, +} +#[test] +fn bindgen_test_layout_if_rxring() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(if_rxring)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_rxring)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxr_adjusted) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_rxring), + "::", + stringify!(rxr_adjusted) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxr_alive) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(if_rxring), "::", stringify!(rxr_alive)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxr_cwm) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_rxring), "::", stringify!(rxr_cwm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxr_lwm) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(if_rxring), "::", stringify!(rxr_lwm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rxr_hwm) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_rxring), "::", stringify!(rxr_hwm)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_rxring_info { + pub ifr_name: [::std::os::raw::c_char; 16usize], + pub ifr_size: u_int, + pub ifr_info: if_rxring, +} +#[test] +fn bindgen_test_layout_if_rxring_info() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(if_rxring_info)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_rxring_info)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifr_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_rxring_info), + "::", + stringify!(ifr_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifr_size) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(if_rxring_info), + "::", + stringify!(ifr_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifr_info) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(if_rxring_info), + "::", + stringify!(ifr_info) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_rxrinfo { + pub ifri_total: u_int, + pub ifri_entries: *mut if_rxring_info, +} +#[test] +fn bindgen_test_layout_if_rxrinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_rxrinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_rxrinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifri_total) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_rxrinfo), + "::", + stringify!(ifri_total) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifri_entries) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_rxrinfo), + "::", + stringify!(ifri_entries) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_data { + pub ifi_type: u_char, + pub ifi_addrlen: u_char, + pub ifi_hdrlen: u_char, + pub ifi_link_state: u_char, + pub ifi_mtu: u_int32_t, + pub ifi_metric: u_int32_t, + pub ifi_rdomain: u_int32_t, + pub ifi_baudrate: u_int64_t, + pub ifi_ipackets: u_int64_t, + pub ifi_ierrors: u_int64_t, + pub ifi_opackets: u_int64_t, + pub ifi_oerrors: u_int64_t, + pub ifi_collisions: u_int64_t, + pub ifi_ibytes: u_int64_t, + pub ifi_obytes: u_int64_t, + pub ifi_imcasts: u_int64_t, + pub ifi_omcasts: u_int64_t, + pub ifi_iqdrops: u_int64_t, + pub ifi_oqdrops: u_int64_t, + pub ifi_noproto: u_int64_t, + pub ifi_capabilities: u_int32_t, + pub ifi_lastchange: timeval, +} +#[test] +fn bindgen_test_layout_if_data() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 144usize, + concat!("Size of: ", stringify!(if_data)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_type) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_addrlen) as usize - ptr as usize }, + 1usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_addrlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_hdrlen) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_hdrlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_link_state) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_link_state) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_mtu) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_mtu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_metric) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_metric)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_rdomain) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_rdomain)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_baudrate) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_baudrate)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ipackets) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_ipackets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ierrors) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_ierrors)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_opackets) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_opackets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_oerrors) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_oerrors)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_collisions) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_collisions) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_ibytes) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_ibytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_obytes) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_obytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_imcasts) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_imcasts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_omcasts) as usize - ptr as usize }, + 88usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_omcasts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_iqdrops) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_iqdrops)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_oqdrops) as usize - ptr as usize }, + 104usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_oqdrops)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_noproto) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(if_data), "::", stringify!(ifi_noproto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_capabilities) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_capabilities) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifi_lastchange) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(if_data), + "::", + stringify!(ifi_lastchange) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_status_description { + pub ifs_type: u_char, + pub ifs_state: u_char, + pub ifs_string: *const ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_if_status_description() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(if_status_description)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_status_description)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifs_type) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_status_description), + "::", + stringify!(ifs_type) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifs_state) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(if_status_description), + "::", + stringify!(ifs_state) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifs_string) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_status_description), + "::", + stringify!(ifs_string) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_msghdr { + pub ifm_msglen: u_short, + pub ifm_version: u_char, + pub ifm_type: u_char, + pub ifm_hdrlen: u_short, + pub ifm_index: u_short, + pub ifm_tableid: u_short, + pub ifm_pad1: u_char, + pub ifm_pad2: u_char, + pub ifm_addrs: ::std::os::raw::c_int, + pub ifm_flags: ::std::os::raw::c_int, + pub ifm_xflags: ::std::os::raw::c_int, + pub ifm_data: if_data, +} +#[test] +fn bindgen_test_layout_if_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 168usize, + concat!("Size of: ", stringify!(if_msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_msglen) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_msglen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(if_msghdr), + "::", + stringify!(ifm_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_type) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_hdrlen) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_hdrlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_index) as usize - ptr as usize }, + 6usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_index)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_tableid) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_msghdr), + "::", + stringify!(ifm_tableid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_pad1) as usize - ptr as usize }, + 10usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_pad1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_pad2) as usize - ptr as usize }, + 11usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_pad2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_addrs) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_addrs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_flags) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_xflags) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_xflags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_data) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(if_msghdr), "::", stringify!(ifm_data)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifa_msghdr { + pub ifam_msglen: u_short, + pub ifam_version: u_char, + pub ifam_type: u_char, + pub ifam_hdrlen: u_short, + pub ifam_index: u_short, + pub ifam_tableid: u_short, + pub ifam_pad1: u_char, + pub ifam_pad2: u_char, + pub ifam_addrs: ::std::os::raw::c_int, + pub ifam_flags: ::std::os::raw::c_int, + pub ifam_metric: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ifa_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(ifa_msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifa_msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_type) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(ifa_msghdr), "::", stringify!(ifam_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_hdrlen) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_hdrlen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_index) as usize - ptr as usize }, + 6usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_tableid) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_tableid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_pad1) as usize - ptr as usize }, + 10usize, + concat!("Offset of field: ", stringify!(ifa_msghdr), "::", stringify!(ifam_pad1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_pad2) as usize - ptr as usize }, + 11usize, + concat!("Offset of field: ", stringify!(ifa_msghdr), "::", stringify!(ifam_pad2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_addrs) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_addrs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_flags) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifam_metric) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(ifa_msghdr), + "::", + stringify!(ifam_metric) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_announcemsghdr { + pub ifan_msglen: u_short, + pub ifan_version: u_char, + pub ifan_type: u_char, + pub ifan_hdrlen: u_short, + pub ifan_index: u_short, + pub ifan_what: u_short, + pub ifan_name: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_if_announcemsghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 26usize, + concat!("Size of: ", stringify!(if_announcemsghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(if_announcemsghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_type) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_type) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_hdrlen) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_hdrlen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_index) as usize - ptr as usize }, + 6usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_what) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_what) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifan_name) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(if_announcemsghdr), + "::", + stringify!(ifan_name) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_ieee80211_data { + pub ifie_channel: u8, + pub ifie_nwid_len: u8, + pub ifie_flags: u32, + pub ifie_xflags: u32, + pub ifie_nwid: [u8; 32usize], + pub ifie_addr: [u8; 6usize], +} +#[test] +fn bindgen_test_layout_if_ieee80211_data() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 52usize, + concat!("Size of: ", stringify!(if_ieee80211_data)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_ieee80211_data)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifie_channel) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_data), + "::", + stringify!(ifie_channel) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifie_nwid_len) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_data), + "::", + stringify!(ifie_nwid_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifie_flags) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_data), + "::", + stringify!(ifie_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifie_xflags) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_data), + "::", + stringify!(ifie_xflags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifie_nwid) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_data), + "::", + stringify!(ifie_nwid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifie_addr) as usize - ptr as usize }, + 44usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_data), + "::", + stringify!(ifie_addr) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_ieee80211_msghdr { + pub ifim_msglen: u16, + pub ifim_version: u8, + pub ifim_type: u8, + pub ifim_hdrlen: u16, + pub ifim_index: u16, + pub ifim_tableid: u16, + pub ifim_ifie: if_ieee80211_data, +} +#[test] +fn bindgen_test_layout_if_ieee80211_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(if_ieee80211_msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_ieee80211_msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifim_msglen) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_msghdr), + "::", + stringify!(ifim_msglen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifim_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_msghdr), + "::", + stringify!(ifim_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifim_type) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_msghdr), + "::", + stringify!(ifim_type) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifim_hdrlen) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_msghdr), + "::", + stringify!(ifim_hdrlen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifim_index) as usize - ptr as usize }, + 6usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_msghdr), + "::", + stringify!(ifim_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifim_tableid) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_msghdr), + "::", + stringify!(ifim_tableid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifim_ifie) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(if_ieee80211_msghdr), + "::", + stringify!(ifim_ifie) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_nameindex_msg { + pub if_index: ::std::os::raw::c_uint, + pub if_name: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_if_nameindex_msg() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(if_nameindex_msg)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(if_nameindex_msg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_index) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_nameindex_msg), + "::", + stringify!(if_index) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).if_name) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(if_nameindex_msg), + "::", + stringify!(if_name) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifg_req { + pub ifgrq_ifgrqu: ifg_req__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union ifg_req__bindgen_ty_1 { + pub ifgrqu_group: [::std::os::raw::c_char; 16usize], + pub ifgrqu_member: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_ifg_req__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifg_req__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(ifg_req__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgrqu_group) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifg_req__bindgen_ty_1), + "::", + stringify!(ifgrqu_group) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgrqu_member) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifg_req__bindgen_ty_1), + "::", + stringify!(ifgrqu_member) + ) + ); +} +#[test] +fn bindgen_test_layout_ifg_req() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifg_req)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(ifg_req)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgrq_ifgrqu) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifg_req), "::", stringify!(ifgrq_ifgrqu)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifg_attrib { + pub ifg_carp_demoted: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ifg_attrib() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(ifg_attrib)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifg_attrib)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifg_carp_demoted) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifg_attrib), + "::", + stringify!(ifg_carp_demoted) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifgroupreq { + pub ifgr_name: [::std::os::raw::c_char; 16usize], + pub ifgr_len: u_int, + pub ifgr_ifgru: ifgroupreq__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union ifgroupreq__bindgen_ty_1 { + pub ifgru_group: [::std::os::raw::c_char; 16usize], + pub ifgru_groups: *mut ifg_req, + pub ifgru_attrib: ifg_attrib, +} +#[test] +fn bindgen_test_layout_ifgroupreq__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifgroupreq__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifgroupreq__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgru_group) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifgroupreq__bindgen_ty_1), + "::", + stringify!(ifgru_group) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgru_groups) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifgroupreq__bindgen_ty_1), + "::", + stringify!(ifgru_groups) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgru_attrib) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifgroupreq__bindgen_ty_1), + "::", + stringify!(ifgru_attrib) + ) + ); +} +#[test] +fn bindgen_test_layout_ifgroupreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(ifgroupreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifgroupreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgr_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifgroupreq), "::", stringify!(ifgr_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgr_len) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifgroupreq), "::", stringify!(ifgr_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifgr_ifgru) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(ifgroupreq), + "::", + stringify!(ifgr_ifgru) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifreq { + pub ifr_name: [::std::os::raw::c_char; 16usize], + pub ifr_ifru: ifreq__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union ifreq__bindgen_ty_1 { + pub ifru_addr: sockaddr, + pub ifru_dstaddr: sockaddr, + pub ifru_broadaddr: sockaddr, + pub ifru_flags: ::std::os::raw::c_short, + pub ifru_metric: ::std::os::raw::c_int, + pub ifru_vnetid: i64, + pub ifru_media: u64, + pub ifru_data: caddr_t, + pub ifru_index: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_ifreq__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifreq__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifreq__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_dstaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_dstaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_broadaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_broadaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_flags) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_metric) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_metric) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_vnetid) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_vnetid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_media) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_media) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_data) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_data) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifru_index) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifreq__bindgen_ty_1), + "::", + stringify!(ifru_index) + ) + ); +} +#[test] +fn bindgen_test_layout_ifreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(ifreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifr_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifreq), "::", stringify!(ifr_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifr_ifru) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(ifreq), "::", stringify!(ifr_ifru)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifaliasreq { + pub ifra_name: [::std::os::raw::c_char; 16usize], + pub ifra_ifrau: ifaliasreq__bindgen_ty_1, + pub ifra_dstaddr: sockaddr, + pub ifra_mask: sockaddr, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union ifaliasreq__bindgen_ty_1 { + pub ifrau_addr: sockaddr, + pub ifrau_align: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ifaliasreq__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifaliasreq__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifaliasreq__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrau_addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifaliasreq__bindgen_ty_1), + "::", + stringify!(ifrau_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifrau_align) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifaliasreq__bindgen_ty_1), + "::", + stringify!(ifrau_align) + ) + ); +} +#[test] +fn bindgen_test_layout_ifaliasreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(ifaliasreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifaliasreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifaliasreq), "::", stringify!(ifra_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_ifrau) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ifaliasreq), + "::", + stringify!(ifra_ifrau) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_dstaddr) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(ifaliasreq), + "::", + stringify!(ifra_dstaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifra_mask) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(ifaliasreq), "::", stringify!(ifra_mask)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifmediareq { + pub ifm_name: [::std::os::raw::c_char; 16usize], + pub ifm_current: u64, + pub ifm_mask: u64, + pub ifm_status: u64, + pub ifm_active: u64, + pub ifm_count: ::std::os::raw::c_int, + pub ifm_ulist: *mut u64, +} +#[test] +fn bindgen_test_layout_ifmediareq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 64usize, + concat!("Size of: ", stringify!(ifmediareq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifmediareq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifmediareq), "::", stringify!(ifm_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_current) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ifmediareq), + "::", + stringify!(ifm_current) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_mask) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(ifmediareq), "::", stringify!(ifm_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_status) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(ifmediareq), + "::", + stringify!(ifm_status) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_active) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(ifmediareq), + "::", + stringify!(ifm_active) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_count) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(ifmediareq), "::", stringify!(ifm_count)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifm_ulist) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(ifmediareq), "::", stringify!(ifm_ulist)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifkalivereq { + pub ikar_name: [::std::os::raw::c_char; 16usize], + pub ikar_timeo: ::std::os::raw::c_int, + pub ikar_cnt: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ifkalivereq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(ifkalivereq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ifkalivereq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ikar_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifkalivereq), + "::", + stringify!(ikar_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ikar_timeo) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ifkalivereq), + "::", + stringify!(ikar_timeo) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ikar_cnt) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(ifkalivereq), "::", stringify!(ikar_cnt)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ifconf { + pub ifc_len: ::std::os::raw::c_int, + pub ifc_ifcu: ifconf__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union ifconf__bindgen_ty_1 { + pub ifcu_buf: caddr_t, + pub ifcu_req: *mut ifreq, +} +#[test] +fn bindgen_test_layout_ifconf__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(ifconf__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifconf__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcu_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifconf__bindgen_ty_1), + "::", + stringify!(ifcu_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifcu_req) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ifconf__bindgen_ty_1), + "::", + stringify!(ifcu_req) + ) + ); +} +#[test] +fn bindgen_test_layout_ifconf() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ifconf)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(ifconf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifc_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ifconf), "::", stringify!(ifc_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifc_ifcu) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(ifconf), "::", stringify!(ifc_ifcu)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_laddrreq { + pub iflr_name: [::std::os::raw::c_char; 16usize], + pub flags: ::std::os::raw::c_uint, + pub prefixlen: ::std::os::raw::c_uint, + pub addr: sockaddr_storage, + pub dstaddr: sockaddr_storage, +} +#[test] +fn bindgen_test_layout_if_laddrreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 536usize, + concat!("Size of: ", stringify!(if_laddrreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(if_laddrreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iflr_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_laddrreq), + "::", + stringify!(iflr_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_laddrreq), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).prefixlen) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(if_laddrreq), + "::", + stringify!(prefixlen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(if_laddrreq), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dstaddr) as usize - ptr as usize }, + 280usize, + concat!("Offset of field: ", stringify!(if_laddrreq), "::", stringify!(dstaddr)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_afreq { + pub ifar_name: [::std::os::raw::c_char; 16usize], + pub ifar_af: sa_family_t, +} +#[test] +fn bindgen_test_layout_if_afreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 17usize, + concat!("Size of: ", stringify!(if_afreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_afreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifar_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_afreq), "::", stringify!(ifar_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifar_af) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_afreq), "::", stringify!(ifar_af)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_parent { + pub ifp_name: [::std::os::raw::c_char; 16usize], + pub ifp_parent: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_if_parent() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(if_parent)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifp_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(if_parent), "::", stringify!(ifp_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifp_parent) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_parent), "::", stringify!(ifp_parent)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct if_sffpage { + pub sff_ifname: [::std::os::raw::c_char; 16usize], + pub sff_addr: u8, + pub sff_page: u8, + pub sff_data: [u8; 256usize], +} +#[test] +fn bindgen_test_layout_if_sffpage() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 274usize, + concat!("Size of: ", stringify!(if_sffpage)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(if_sffpage)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sff_ifname) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(if_sffpage), + "::", + stringify!(sff_ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sff_addr) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(if_sffpage), "::", stringify!(sff_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sff_page) as usize - ptr as usize }, + 17usize, + concat!("Offset of field: ", stringify!(if_sffpage), "::", stringify!(sff_page)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sff_data) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(if_sffpage), "::", stringify!(sff_data)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct arphdr { + pub ar_hrd: u_int16_t, + pub ar_pro: u_int16_t, + pub ar_hln: u_int8_t, + pub ar_pln: u_int8_t, + pub ar_op: u_int16_t, +} +#[test] +fn bindgen_test_layout_arphdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(arphdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(arphdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ar_hrd) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(arphdr), "::", stringify!(ar_hrd)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ar_pro) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(arphdr), "::", stringify!(ar_pro)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ar_hln) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(arphdr), "::", stringify!(ar_hln)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ar_pln) as usize - ptr as usize }, + 5usize, + concat!("Offset of field: ", stringify!(arphdr), "::", stringify!(ar_pln)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ar_op) as usize - ptr as usize }, + 6usize, + concat!("Offset of field: ", stringify!(arphdr), "::", stringify!(ar_op)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct arpreq { + pub arp_pa: sockaddr, + pub arp_ha: sockaddr, + pub arp_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_arpreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 36usize, + concat!("Size of: ", stringify!(arpreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(arpreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).arp_pa) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(arpreq), "::", stringify!(arp_pa)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).arp_ha) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(arpreq), "::", stringify!(arp_ha)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).arp_flags) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(arpreq), "::", stringify!(arp_flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rb_type { + pub t_compare: ::std::option::Option< + unsafe extern "C" fn( + arg1: *const ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int, + >, + pub t_augment: ::std::option::Option, + pub t_offset: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_rb_type() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(rb_type)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rb_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).t_compare) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rb_type), "::", stringify!(t_compare)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).t_augment) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(rb_type), "::", stringify!(t_augment)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).t_offset) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(rb_type), "::", stringify!(t_offset)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rb_tree { + pub rbt_root: *mut rb_entry, +} +#[test] +fn bindgen_test_layout_rb_tree() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(rb_tree)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rb_tree)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbt_root) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rb_tree), "::", stringify!(rbt_root)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rb_entry { + pub rbt_parent: *mut rb_entry, + pub rbt_left: *mut rb_entry, + pub rbt_right: *mut rb_entry, + pub rbt_color: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_rb_entry() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(rb_entry)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rb_entry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbt_parent) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rb_entry), "::", stringify!(rbt_parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbt_left) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(rb_entry), "::", stringify!(rbt_left)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbt_right) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(rb_entry), "::", stringify!(rbt_right)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbt_color) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(rb_entry), "::", stringify!(rbt_color)) + ); +} +extern "C" { + pub fn _rb_insert( + arg1: *const rb_type, + arg2: *mut rb_tree, + arg3: *mut ::std::os::raw::c_void, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_remove( + arg1: *const rb_type, + arg2: *mut rb_tree, + arg3: *mut ::std::os::raw::c_void, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_find( + arg1: *const rb_type, + arg2: *mut rb_tree, + arg3: *const ::std::os::raw::c_void, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_nfind( + arg1: *const rb_type, + arg2: *mut rb_tree, + arg3: *const ::std::os::raw::c_void, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_root(arg1: *const rb_type, arg2: *mut rb_tree) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_min(arg1: *const rb_type, arg2: *mut rb_tree) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_max(arg1: *const rb_type, arg2: *mut rb_tree) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_next(arg1: *const rb_type, arg2: *mut ::std::os::raw::c_void) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_prev(arg1: *const rb_type, arg2: *mut ::std::os::raw::c_void) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_left(arg1: *const rb_type, arg2: *mut ::std::os::raw::c_void) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_right(arg1: *const rb_type, arg2: *mut ::std::os::raw::c_void) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_parent(arg1: *const rb_type, arg2: *mut ::std::os::raw::c_void) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn _rb_set_left(arg1: *const rb_type, arg2: *mut ::std::os::raw::c_void, arg3: *mut ::std::os::raw::c_void); +} +extern "C" { + pub fn _rb_set_right(arg1: *const rb_type, arg2: *mut ::std::os::raw::c_void, arg3: *mut ::std::os::raw::c_void); +} +extern "C" { + pub fn _rb_set_parent(arg1: *const rb_type, arg2: *mut ::std::os::raw::c_void, arg3: *mut ::std::os::raw::c_void); +} +extern "C" { + pub fn _rb_poison(arg1: *const rb_type, arg2: *mut ::std::os::raw::c_void, arg3: ::std::os::raw::c_ulong); +} +extern "C" { + pub fn _rb_check( + arg1: *const rb_type, + arg2: *mut ::std::os::raw::c_void, + arg3: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +pub const lock_class_index_LO_CLASS_KERNEL_LOCK: lock_class_index = 0; +pub const lock_class_index_LO_CLASS_SCHED_LOCK: lock_class_index = 1; +pub const lock_class_index_LO_CLASS_MUTEX: lock_class_index = 2; +pub const lock_class_index_LO_CLASS_RWLOCK: lock_class_index = 3; +pub const lock_class_index_LO_CLASS_RRWLOCK: lock_class_index = 4; +pub type lock_class_index = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct lock_object { + pub lo_type: *const lock_type, + pub lo_name: *const ::std::os::raw::c_char, + pub lo_witness: *mut witness, + pub lo_flags: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_lock_object() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(lock_object)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(lock_object)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lo_type) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(lock_object), "::", stringify!(lo_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lo_name) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(lock_object), "::", stringify!(lo_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lo_witness) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(lock_object), + "::", + stringify!(lo_witness) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lo_flags) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(lock_object), "::", stringify!(lo_flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct lock_type { + pub lt_name: *const ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_lock_type() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(lock_type)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(lock_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lt_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(lock_type), "::", stringify!(lt_name)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct proc_ { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rwlock { + pub rwl_owner: ::std::os::raw::c_ulong, + pub rwl_name: *const ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_rwlock() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(rwlock)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rwlock)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rwl_owner) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rwlock), "::", stringify!(rwl_owner)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rwl_name) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(rwlock), "::", stringify!(rwl_name)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rrwlock { + pub rrwl_lock: rwlock, + pub rrwl_wcnt: u32, +} +#[test] +fn bindgen_test_layout_rrwlock() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(rrwlock)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rrwlock)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rrwl_lock) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rrwlock), "::", stringify!(rrwl_lock)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rrwl_wcnt) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(rrwlock), "::", stringify!(rrwl_wcnt)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct refcnt { + pub r_refs: ::std::os::raw::c_uint, + pub r_traceidx: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_refcnt() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(refcnt)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(refcnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).r_refs) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(refcnt), "::", stringify!(r_refs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).r_traceidx) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(refcnt), "::", stringify!(r_traceidx)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct circq { + pub next: *mut circq, + pub prev: *mut circq, +} +#[test] +fn bindgen_test_layout_circq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(circq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(circq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).next) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(circq), "::", stringify!(next)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).prev) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(circq), "::", stringify!(prev)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timeout { + pub to_list: circq, + pub to_abstime: timespec, + pub to_func: ::std::option::Option, + pub to_arg: *mut ::std::os::raw::c_void, + pub to_process: *mut process, + pub to_time: ::std::os::raw::c_int, + pub to_flags: ::std::os::raw::c_int, + pub to_kclock: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_timeout() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 72usize, + concat!("Size of: ", stringify!(timeout)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(timeout)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).to_list) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(timeout), "::", stringify!(to_list)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).to_abstime) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(timeout), "::", stringify!(to_abstime)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).to_func) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(timeout), "::", stringify!(to_func)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).to_arg) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(timeout), "::", stringify!(to_arg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).to_process) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(timeout), "::", stringify!(to_process)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).to_time) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(timeout), "::", stringify!(to_time)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).to_flags) as usize - ptr as usize }, + 60usize, + concat!("Offset of field: ", stringify!(timeout), "::", stringify!(to_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).to_kclock) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(timeout), "::", stringify!(to_kclock)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct timeoutstat { + pub tos_added: u64, + pub tos_cancelled: u64, + pub tos_deleted: u64, + pub tos_late: u64, + pub tos_pending: u64, + pub tos_readded: u64, + pub tos_rescheduled: u64, + pub tos_run_softclock: u64, + pub tos_run_thread: u64, + pub tos_scheduled: u64, + pub tos_softclocks: u64, + pub tos_thread_wakeups: u64, +} +#[test] +fn bindgen_test_layout_timeoutstat() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(timeoutstat)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(timeoutstat)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_added) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_added) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_cancelled) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_cancelled) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_deleted) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_deleted) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_late) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(timeoutstat), "::", stringify!(tos_late)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_pending) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_pending) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_readded) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_readded) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_rescheduled) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_rescheduled) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_run_softclock) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_run_softclock) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_run_thread) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_run_thread) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_scheduled) as usize - ptr as usize }, + 72usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_scheduled) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_softclocks) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_softclocks) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos_thread_wakeups) as usize - ptr as usize }, + 88usize, + concat!( + "Offset of field: ", + stringify!(timeoutstat), + "::", + stringify!(tos_thread_wakeups) + ) + ); +} +pub type in_addr_t = __in_addr_t; +pub type in_port_t = __in_port_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct in_addr { + pub s_addr: in_addr_t, +} +#[test] +fn bindgen_test_layout_in_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(in_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).s_addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(in_addr), "::", stringify!(s_addr)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_in { + pub sin_len: u_int8_t, + pub sin_family: sa_family_t, + pub sin_port: in_port_t, + pub sin_addr: in_addr, + pub sin_zero: [i8; 8usize], +} +#[test] +fn bindgen_test_layout_sockaddr_in() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(sockaddr_in)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_in)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in), + "::", + stringify!(sin_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_port) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_addr) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin_zero) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(sockaddr_in), "::", stringify!(sin_zero)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_opts { + pub ip_dst: in_addr, + pub ip_opts: [i8; 40usize], +} +#[test] +fn bindgen_test_layout_ip_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 44usize, + concat!("Size of: ", stringify!(ip_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip_dst) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(ip_opts), "::", stringify!(ip_dst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip_opts) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(ip_opts), "::", stringify!(ip_opts)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_mreq { + pub imr_multiaddr: in_addr, + pub imr_interface: in_addr, +} +#[test] +fn bindgen_test_layout_ip_mreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(ip_mreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_mreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq), + "::", + stringify!(imr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_interface) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(ip_mreq), + "::", + stringify!(imr_interface) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip_mreqn { + pub imr_multiaddr: in_addr, + pub imr_address: in_addr, + pub imr_ifindex: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_ip_mreqn() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(ip_mreqn)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip_mreqn)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip_mreqn), + "::", + stringify!(imr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_address) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(ip_mreqn), "::", stringify!(imr_address)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).imr_ifindex) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(ip_mreqn), "::", stringify!(imr_ifindex)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct in6_addr { + pub __u6_addr: in6_addr__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union in6_addr__bindgen_ty_1 { + pub __u6_addr8: [u_int8_t; 16usize], + pub __u6_addr16: [u_int16_t; 8usize], + pub __u6_addr32: [u_int32_t; 4usize], +} +#[test] +fn bindgen_test_layout_in6_addr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(in6_addr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in6_addr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_addr__bindgen_ty_1), + "::", + stringify!(__u6_addr8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr16) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_addr__bindgen_ty_1), + "::", + stringify!(__u6_addr16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr32) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_addr__bindgen_ty_1), + "::", + stringify!(__u6_addr32) + ) + ); +} +#[test] +fn bindgen_test_layout_in6_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(in6_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in6_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).__u6_addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(in6_addr), "::", stringify!(__u6_addr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct sockaddr_in6 { + pub sin6_len: u_int8_t, + pub sin6_family: sa_family_t, + pub sin6_port: in_port_t, + pub sin6_flowinfo: u_int32_t, + pub sin6_addr: in6_addr, + pub sin6_scope_id: u_int32_t, +} +#[test] +fn bindgen_test_layout_sockaddr_in6() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 28usize, + concat!("Size of: ", stringify!(sockaddr_in6)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(sockaddr_in6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_port) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_port) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_flowinfo) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_flowinfo) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_addr) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6_scope_id) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_in6), + "::", + stringify!(sin6_scope_id) + ) + ); +} +extern "C" { + pub static in6addr_any: in6_addr; +} +extern "C" { + pub static in6addr_loopback: in6_addr; +} +extern "C" { + pub static in6addr_intfacelocal_allnodes: in6_addr; +} +extern "C" { + pub static in6addr_linklocal_allnodes: in6_addr; +} +extern "C" { + pub static in6addr_linklocal_allrouters: in6_addr; +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ipv6_mreq { + pub ipv6mr_multiaddr: in6_addr, + pub ipv6mr_interface: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_ipv6_mreq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(ipv6_mreq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ipv6_mreq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipv6mr_multiaddr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ipv6_mreq), + "::", + stringify!(ipv6mr_multiaddr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipv6mr_interface) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(ipv6_mreq), + "::", + stringify!(ipv6mr_interface) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct in6_pktinfo { + pub ipi6_addr: in6_addr, + pub ipi6_ifindex: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_in6_pktinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(in6_pktinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(in6_pktinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipi6_addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(in6_pktinfo), + "::", + stringify!(ipi6_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ipi6_ifindex) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(in6_pktinfo), + "::", + stringify!(ipi6_ifindex) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct ip6_mtuinfo { + pub ip6m_addr: sockaddr_in6, + pub ip6m_mtu: u_int32_t, +} +#[test] +fn bindgen_test_layout_ip6_mtuinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(ip6_mtuinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(ip6_mtuinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip6m_addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ip6_mtuinfo), + "::", + stringify!(ip6m_addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ip6m_mtu) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(ip6_mtuinfo), "::", stringify!(ip6m_mtu)) + ); +} +extern "C" { + pub fn inet6_opt_init(arg1: *mut ::std::os::raw::c_void, arg2: socklen_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_append( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: u_int8_t, + arg5: socklen_t, + arg6: u_int8_t, + arg7: *mut *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_finish( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_set_val( + arg1: *mut ::std::os::raw::c_void, + arg2: ::std::os::raw::c_int, + arg3: *mut ::std::os::raw::c_void, + arg4: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_next( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: *mut u_int8_t, + arg5: *mut socklen_t, + arg6: *mut *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_find( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: u_int8_t, + arg5: *mut socklen_t, + arg6: *mut *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_opt_get_val( + arg1: *mut ::std::os::raw::c_void, + arg2: ::std::os::raw::c_int, + arg3: *mut ::std::os::raw::c_void, + arg4: socklen_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_space(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> socklen_t; +} +extern "C" { + pub fn inet6_rth_init( + arg1: *mut ::std::os::raw::c_void, + arg2: socklen_t, + arg3: ::std::os::raw::c_int, + arg4: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn inet6_rth_add(arg1: *mut ::std::os::raw::c_void, arg2: *const in6_addr) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_reverse( + arg1: *const ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_segments(arg1: *const ::std::os::raw::c_void) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn inet6_rth_getaddr(arg1: *const ::std::os::raw::c_void, arg2: ::std::os::raw::c_int) -> *mut in6_addr; +} +extern "C" { + pub fn bindresvport(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr_in) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn bindresvport_sa(arg1: ::std::os::raw::c_int, arg2: *mut sockaddr) -> ::std::os::raw::c_int; +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_node { + pub rn_mklist: *mut radix_mask, + pub rn_p: *mut radix_node, + pub rn_b: ::std::os::raw::c_short, + pub rn_bmask: ::std::os::raw::c_char, + pub rn_flags: u_char, + pub rn_u: radix_node__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union radix_node__bindgen_ty_1 { + pub rn_leaf: radix_node__bindgen_ty_1__bindgen_ty_1, + pub rn_node: radix_node__bindgen_ty_1__bindgen_ty_2, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct radix_node__bindgen_ty_1__bindgen_ty_1 { + pub rn_Key: caddr_t, + pub rn_Mask: caddr_t, + pub rn_Dupedkey: *mut radix_node, +} +#[test] +fn bindgen_test_layout_radix_node__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Key) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rn_Key) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Mask) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rn_Mask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Dupedkey) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rn_Dupedkey) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct radix_node__bindgen_ty_1__bindgen_ty_2 { + pub rn_Off: ::std::os::raw::c_int, + pub rn_L: *mut radix_node, + pub rn_R: *mut radix_node, +} +#[test] +fn bindgen_test_layout_radix_node__bindgen_ty_1__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node__bindgen_ty_1__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_Off) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(rn_Off) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_L) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(rn_L) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_R) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1__bindgen_ty_2), + "::", + stringify!(rn_R) + ) + ); +} +#[test] +fn bindgen_test_layout_radix_node__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(radix_node__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_leaf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1), + "::", + stringify!(rn_leaf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_node) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node__bindgen_ty_1), + "::", + stringify!(rn_node) + ) + ); +} +#[test] +fn bindgen_test_layout_radix_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(radix_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_mklist) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_mklist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_p) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_p)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_b) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_b)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_bmask) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_bmask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_flags) as usize - ptr as usize }, + 19usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rn_u) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(radix_node), "::", stringify!(rn_u)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_mask { + pub rm_b: ::std::os::raw::c_short, + pub rm_unused: ::std::os::raw::c_char, + pub rm_flags: u_char, + pub rm_mklist: *mut radix_mask, + pub rm_rmu: radix_mask__bindgen_ty_1, + pub rm_refs: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union radix_mask__bindgen_ty_1 { + pub rmu_mask: caddr_t, + pub rmu_leaf: *mut radix_node, +} +#[test] +fn bindgen_test_layout_radix_mask__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(radix_mask__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_mask__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmu_mask) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_mask__bindgen_ty_1), + "::", + stringify!(rmu_mask) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmu_leaf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_mask__bindgen_ty_1), + "::", + stringify!(rmu_leaf) + ) + ); +} +#[test] +fn bindgen_test_layout_radix_mask() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(radix_mask)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_mask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_b) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_b)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_unused) as usize - ptr as usize }, + 2usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_unused)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_flags) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_mklist) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_mklist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_rmu) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_rmu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rm_refs) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(radix_mask), "::", stringify!(rm_refs)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct radix_node_head { + pub rnh_treetop: *mut radix_node, + pub rnh_addrsize: ::std::os::raw::c_int, + pub rnh_pktsize: ::std::os::raw::c_int, + pub rnh_nodes: [radix_node; 3usize], + pub rnh_rtableid: u_int, +} +#[test] +fn bindgen_test_layout_radix_node_head() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 168usize, + concat!("Size of: ", stringify!(radix_node_head)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(radix_node_head)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_treetop) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_treetop) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_addrsize) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_addrsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_pktsize) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_pktsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_nodes) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_nodes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rnh_rtableid) as usize - ptr as usize }, + 160usize, + concat!( + "Offset of field: ", + stringify!(radix_node_head), + "::", + stringify!(rnh_rtableid) + ) + ); +} +extern "C" { + pub fn rn_init(arg1: ::std::os::raw::c_uint); +} +extern "C" { + pub fn rn_inithead(arg1: *mut *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rn_walktree( + arg1: *mut radix_node_head, + arg2: ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut radix_node, + arg2: *mut ::std::os::raw::c_void, + arg3: u_int, + ) -> ::std::os::raw::c_int, + >, + arg3: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rn_addroute( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_void, + arg3: *mut radix_node_head, + arg4: *mut radix_node, + arg5: u_int8_t, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_delete( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_void, + arg3: *mut radix_node_head, + arg4: *mut radix_node, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_lookup( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut ::std::os::raw::c_void, + arg3: *mut radix_node_head, + ) -> *mut radix_node; +} +extern "C" { + pub fn rn_match(arg1: *mut ::std::os::raw::c_void, arg2: *mut radix_node_head) -> *mut radix_node; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_metrics { + pub rmx_pksent: u_int64_t, + pub rmx_expire: i64, + pub rmx_locks: u_int, + pub rmx_mtu: u_int, + pub rmx_refcnt: u_int, + pub rmx_hopcount: u_int, + pub rmx_recvpipe: u_int, + pub rmx_sendpipe: u_int, + pub rmx_ssthresh: u_int, + pub rmx_rtt: u_int, + pub rmx_rttvar: u_int, + pub rmx_pad: u_int, +} +#[test] +fn bindgen_test_layout_rt_metrics() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(rt_metrics)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rt_metrics)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_pksent) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_pksent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_expire) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_expire) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_locks) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(rt_metrics), "::", stringify!(rmx_locks)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_mtu) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(rt_metrics), "::", stringify!(rmx_mtu)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_refcnt) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_refcnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_hopcount) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_hopcount) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_recvpipe) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_recvpipe) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_sendpipe) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_sendpipe) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_ssthresh) as usize - ptr as usize }, + 40usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_ssthresh) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_rtt) as usize - ptr as usize }, + 44usize, + concat!("Offset of field: ", stringify!(rt_metrics), "::", stringify!(rmx_rtt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_rttvar) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(rt_metrics), + "::", + stringify!(rmx_rttvar) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rmx_pad) as usize - ptr as usize }, + 52usize, + concat!("Offset of field: ", stringify!(rt_metrics), "::", stringify!(rmx_pad)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rtstat { + pub rts_badredirect: u_int32_t, + pub rts_dynamic: u_int32_t, + pub rts_newgateway: u_int32_t, + pub rts_unreach: u_int32_t, + pub rts_wildcard: u_int32_t, +} +#[test] +fn bindgen_test_layout_rtstat() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(rtstat)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(rtstat)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_badredirect) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rtstat), + "::", + stringify!(rts_badredirect) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_dynamic) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(rtstat), "::", stringify!(rts_dynamic)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_newgateway) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(rtstat), + "::", + stringify!(rts_newgateway) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_unreach) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(rtstat), "::", stringify!(rts_unreach)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rts_wildcard) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(rtstat), "::", stringify!(rts_wildcard)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_tableinfo { + pub rti_tableid: u_short, + pub rti_domainid: u_short, +} +#[test] +fn bindgen_test_layout_rt_tableinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(rt_tableinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 2usize, + concat!("Alignment of ", stringify!(rt_tableinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_tableid) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rt_tableinfo), + "::", + stringify!(rti_tableid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_domainid) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(rt_tableinfo), + "::", + stringify!(rti_domainid) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_msghdr { + pub rtm_msglen: u_short, + pub rtm_version: u_char, + pub rtm_type: u_char, + pub rtm_hdrlen: u_short, + pub rtm_index: u_short, + pub rtm_tableid: u_short, + pub rtm_priority: u_char, + pub rtm_mpls: u_char, + pub rtm_addrs: ::std::os::raw::c_int, + pub rtm_flags: ::std::os::raw::c_int, + pub rtm_fmask: ::std::os::raw::c_int, + pub rtm_pid: pid_t, + pub rtm_seq: ::std::os::raw::c_int, + pub rtm_errno: ::std::os::raw::c_int, + pub rtm_inits: u_int, + pub rtm_rmx: rt_metrics, +} +#[test] +fn bindgen_test_layout_rt_msghdr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 96usize, + concat!("Size of: ", stringify!(rt_msghdr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rt_msghdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_msglen) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_msglen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_version) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr), + "::", + stringify!(rtm_version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_type) as usize - ptr as usize }, + 3usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_hdrlen) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_hdrlen)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_index) as usize - ptr as usize }, + 6usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_index)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_tableid) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr), + "::", + stringify!(rtm_tableid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_priority) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(rt_msghdr), + "::", + stringify!(rtm_priority) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_mpls) as usize - ptr as usize }, + 11usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_mpls)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_addrs) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_addrs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_flags) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_fmask) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_fmask)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_pid) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_pid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_seq) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_seq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_errno) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_errno)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_inits) as usize - ptr as usize }, + 36usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_inits)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtm_rmx) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(rt_msghdr), "::", stringify!(rtm_rmx)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_rtlabel { + pub sr_len: u_int8_t, + pub sr_family: sa_family_t, + pub sr_label: [::std::os::raw::c_char; 32usize], +} +#[test] +fn bindgen_test_layout_sockaddr_rtlabel() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 34usize, + concat!("Size of: ", stringify!(sockaddr_rtlabel)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(sockaddr_rtlabel)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtlabel), + "::", + stringify!(sr_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtlabel), + "::", + stringify!(sr_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_label) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtlabel), + "::", + stringify!(sr_label) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_rtdns { + pub sr_len: u_int8_t, + pub sr_family: sa_family_t, + pub sr_dns: [::std::os::raw::c_char; 128usize], +} +#[test] +fn bindgen_test_layout_sockaddr_rtdns() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 130usize, + concat!("Size of: ", stringify!(sockaddr_rtdns)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(sockaddr_rtdns)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtdns), + "::", + stringify!(sr_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtdns), + "::", + stringify!(sr_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_dns) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtdns), + "::", + stringify!(sr_dns) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_rtstatic { + pub sr_len: u_int8_t, + pub sr_family: sa_family_t, + pub sr_static: [::std::os::raw::c_char; 128usize], +} +#[test] +fn bindgen_test_layout_sockaddr_rtstatic() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 130usize, + concat!("Size of: ", stringify!(sockaddr_rtstatic)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(sockaddr_rtstatic)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtstatic), + "::", + stringify!(sr_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtstatic), + "::", + stringify!(sr_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_static) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtstatic), + "::", + stringify!(sr_static) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct sockaddr_rtsearch { + pub sr_len: u_int8_t, + pub sr_family: sa_family_t, + pub sr_search: [::std::os::raw::c_char; 128usize], +} +#[test] +fn bindgen_test_layout_sockaddr_rtsearch() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 130usize, + concat!("Size of: ", stringify!(sockaddr_rtsearch)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(sockaddr_rtsearch)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtsearch), + "::", + stringify!(sr_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_family) as usize - ptr as usize }, + 1usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtsearch), + "::", + stringify!(sr_family) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sr_search) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(sockaddr_rtsearch), + "::", + stringify!(sr_search) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rt_addrinfo { + pub rti_addrs: ::std::os::raw::c_int, + pub rti_info: [*const sockaddr; 15usize], + pub rti_flags: ::std::os::raw::c_int, + pub rti_ifa: *mut ifaddr, + pub rti_rtm: *mut rt_msghdr, + pub rti_mpls: u_char, +} +#[test] +fn bindgen_test_layout_rt_addrinfo() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 160usize, + concat!("Size of: ", stringify!(rt_addrinfo)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(rt_addrinfo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_addrs) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(rt_addrinfo), + "::", + stringify!(rti_addrs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_info) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(rt_addrinfo), "::", stringify!(rti_info)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_flags) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(rt_addrinfo), + "::", + stringify!(rti_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_ifa) as usize - ptr as usize }, + 136usize, + concat!("Offset of field: ", stringify!(rt_addrinfo), "::", stringify!(rti_ifa)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_rtm) as usize - ptr as usize }, + 144usize, + concat!("Offset of field: ", stringify!(rt_addrinfo), "::", stringify!(rti_rtm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rti_mpls) as usize - ptr as usize }, + 152usize, + concat!("Offset of field: ", stringify!(rt_addrinfo), "::", stringify!(rti_mpls)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct route { + pub ro_rt: *mut rtentry, + pub ro_generation: u_long, + pub ro_tableid: u_long, + pub __bindgen_anon_1: route__bindgen_ty_1, + pub __bindgen_anon_2: route__bindgen_ty_2, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union route__bindgen_ty_1 { + pub ro_dstsa: sockaddr, + pub ro_dstsin: sockaddr_in, + pub ro_dstsin6: sockaddr_in6, +} +#[test] +fn bindgen_test_layout_route__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 28usize, + concat!("Size of: ", stringify!(route__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(route__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_dstsa) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(route__bindgen_ty_1), + "::", + stringify!(ro_dstsa) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_dstsin) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(route__bindgen_ty_1), + "::", + stringify!(ro_dstsin) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_dstsin6) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(route__bindgen_ty_1), + "::", + stringify!(ro_dstsin6) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union route__bindgen_ty_2 { + pub ro_srcin: in_addr, + pub ro_srcin6: in6_addr, +} +#[test] +fn bindgen_test_layout_route__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(route__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(route__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_srcin) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(route__bindgen_ty_2), + "::", + stringify!(ro_srcin) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_srcin6) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(route__bindgen_ty_2), + "::", + stringify!(ro_srcin6) + ) + ); +} +#[test] +fn bindgen_test_layout_route() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 72usize, + concat!("Size of: ", stringify!(route)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(route)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_rt) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(route), "::", stringify!(ro_rt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_generation) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(route), "::", stringify!(ro_generation)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ro_tableid) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(route), "::", stringify!(ro_tableid)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ip6_hdr { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct mbuf_list { + _unused: [u8; 0], +} +pub type pf_refcnt_t = refcnt; +pub const PF_INOUT: _bindgen_ty_1 = 0; +pub const PF_IN: _bindgen_ty_1 = 1; +pub const PF_OUT: _bindgen_ty_1 = 2; +pub const PF_FWD: _bindgen_ty_1 = 3; +pub type _bindgen_ty_1 = ::std::os::raw::c_uint; +pub const PF_PASS: _bindgen_ty_2 = 0; +pub const PF_DROP: _bindgen_ty_2 = 1; +pub const PF_SCRUB: _bindgen_ty_2 = 2; +pub const PF_NOSCRUB: _bindgen_ty_2 = 3; +pub const PF_NAT: _bindgen_ty_2 = 4; +pub const PF_NONAT: _bindgen_ty_2 = 5; +pub const PF_BINAT: _bindgen_ty_2 = 6; +pub const PF_NOBINAT: _bindgen_ty_2 = 7; +pub const PF_RDR: _bindgen_ty_2 = 8; +pub const PF_NORDR: _bindgen_ty_2 = 9; +pub const PF_SYNPROXY_DROP: _bindgen_ty_2 = 10; +pub const PF_DEFER: _bindgen_ty_2 = 11; +pub const PF_MATCH: _bindgen_ty_2 = 12; +pub const PF_DIVERT: _bindgen_ty_2 = 13; +pub const PF_RT: _bindgen_ty_2 = 14; +pub const PF_AFRT: _bindgen_ty_2 = 15; +pub type _bindgen_ty_2 = ::std::os::raw::c_uint; +pub const PF_TRANS_RULESET: _bindgen_ty_3 = 0; +pub const PF_TRANS_TABLE: _bindgen_ty_3 = 1; +pub type _bindgen_ty_3 = ::std::os::raw::c_uint; +pub const PF_OP_NONE: _bindgen_ty_4 = 0; +pub const PF_OP_IRG: _bindgen_ty_4 = 1; +pub const PF_OP_EQ: _bindgen_ty_4 = 2; +pub const PF_OP_NE: _bindgen_ty_4 = 3; +pub const PF_OP_LT: _bindgen_ty_4 = 4; +pub const PF_OP_LE: _bindgen_ty_4 = 5; +pub const PF_OP_GT: _bindgen_ty_4 = 6; +pub const PF_OP_GE: _bindgen_ty_4 = 7; +pub const PF_OP_XRG: _bindgen_ty_4 = 8; +pub const PF_OP_RRG: _bindgen_ty_4 = 9; +pub type _bindgen_ty_4 = ::std::os::raw::c_uint; +pub const PF_CHANGE_NONE: _bindgen_ty_5 = 0; +pub const PF_CHANGE_ADD_HEAD: _bindgen_ty_5 = 1; +pub const PF_CHANGE_ADD_TAIL: _bindgen_ty_5 = 2; +pub const PF_CHANGE_ADD_BEFORE: _bindgen_ty_5 = 3; +pub const PF_CHANGE_ADD_AFTER: _bindgen_ty_5 = 4; +pub const PF_CHANGE_REMOVE: _bindgen_ty_5 = 5; +pub const PF_CHANGE_GET_TICKET: _bindgen_ty_5 = 6; +pub type _bindgen_ty_5 = ::std::os::raw::c_uint; +pub const PF_GET_NONE: _bindgen_ty_6 = 0; +pub const PF_GET_CLR_CNTR: _bindgen_ty_6 = 1; +pub type _bindgen_ty_6 = ::std::os::raw::c_uint; +pub const PF_SK_WIRE: _bindgen_ty_7 = 0; +pub const PF_SK_STACK: _bindgen_ty_7 = 1; +pub const PF_SK_BOTH: _bindgen_ty_7 = 2; +pub type _bindgen_ty_7 = ::std::os::raw::c_uint; +pub const PF_PEER_SRC: _bindgen_ty_8 = 0; +pub const PF_PEER_DST: _bindgen_ty_8 = 1; +pub const PF_PEER_BOTH: _bindgen_ty_8 = 2; +pub type _bindgen_ty_8 = ::std::os::raw::c_uint; +pub const PFTM_TCP_FIRST_PACKET: _bindgen_ty_9 = 0; +pub const PFTM_TCP_OPENING: _bindgen_ty_9 = 1; +pub const PFTM_TCP_ESTABLISHED: _bindgen_ty_9 = 2; +pub const PFTM_TCP_CLOSING: _bindgen_ty_9 = 3; +pub const PFTM_TCP_FIN_WAIT: _bindgen_ty_9 = 4; +pub const PFTM_TCP_CLOSED: _bindgen_ty_9 = 5; +pub const PFTM_UDP_FIRST_PACKET: _bindgen_ty_9 = 6; +pub const PFTM_UDP_SINGLE: _bindgen_ty_9 = 7; +pub const PFTM_UDP_MULTIPLE: _bindgen_ty_9 = 8; +pub const PFTM_ICMP_FIRST_PACKET: _bindgen_ty_9 = 9; +pub const PFTM_ICMP_ERROR_REPLY: _bindgen_ty_9 = 10; +pub const PFTM_OTHER_FIRST_PACKET: _bindgen_ty_9 = 11; +pub const PFTM_OTHER_SINGLE: _bindgen_ty_9 = 12; +pub const PFTM_OTHER_MULTIPLE: _bindgen_ty_9 = 13; +pub const PFTM_FRAG: _bindgen_ty_9 = 14; +pub const PFTM_INTERVAL: _bindgen_ty_9 = 15; +pub const PFTM_ADAPTIVE_START: _bindgen_ty_9 = 16; +pub const PFTM_ADAPTIVE_END: _bindgen_ty_9 = 17; +pub const PFTM_SRC_NODE: _bindgen_ty_9 = 18; +pub const PFTM_TS_DIFF: _bindgen_ty_9 = 19; +pub const PFTM_MAX: _bindgen_ty_9 = 20; +pub const PFTM_PURGE: _bindgen_ty_9 = 21; +pub const PFTM_UNLINKED: _bindgen_ty_9 = 22; +pub type _bindgen_ty_9 = ::std::os::raw::c_uint; +pub const PF_NOPFROUTE: _bindgen_ty_10 = 0; +pub const PF_ROUTETO: _bindgen_ty_10 = 1; +pub const PF_DUPTO: _bindgen_ty_10 = 2; +pub const PF_REPLYTO: _bindgen_ty_10 = 3; +pub type _bindgen_ty_10 = ::std::os::raw::c_uint; +pub const PF_LIMIT_STATES: _bindgen_ty_11 = 0; +pub const PF_LIMIT_SRC_NODES: _bindgen_ty_11 = 1; +pub const PF_LIMIT_FRAGS: _bindgen_ty_11 = 2; +pub const PF_LIMIT_TABLES: _bindgen_ty_11 = 3; +pub const PF_LIMIT_TABLE_ENTRIES: _bindgen_ty_11 = 4; +pub const PF_LIMIT_PKTDELAY_PKTS: _bindgen_ty_11 = 5; +pub const PF_LIMIT_ANCHORS: _bindgen_ty_11 = 6; +pub const PF_LIMIT_MAX: _bindgen_ty_11 = 7; +pub type _bindgen_ty_11 = ::std::os::raw::c_uint; +pub const PF_POOL_NONE: _bindgen_ty_12 = 0; +pub const PF_POOL_BITMASK: _bindgen_ty_12 = 1; +pub const PF_POOL_RANDOM: _bindgen_ty_12 = 2; +pub const PF_POOL_SRCHASH: _bindgen_ty_12 = 3; +pub const PF_POOL_ROUNDROBIN: _bindgen_ty_12 = 4; +pub const PF_POOL_LEASTSTATES: _bindgen_ty_12 = 5; +pub type _bindgen_ty_12 = ::std::os::raw::c_uint; +pub const PF_ADDR_ADDRMASK: _bindgen_ty_13 = 0; +pub const PF_ADDR_NOROUTE: _bindgen_ty_13 = 1; +pub const PF_ADDR_DYNIFTL: _bindgen_ty_13 = 2; +pub const PF_ADDR_TABLE: _bindgen_ty_13 = 3; +pub const PF_ADDR_RTLABEL: _bindgen_ty_13 = 4; +pub const PF_ADDR_URPFFAILED: _bindgen_ty_13 = 5; +pub const PF_ADDR_RANGE: _bindgen_ty_13 = 6; +pub const PF_ADDR_NONE: _bindgen_ty_13 = 7; +pub type _bindgen_ty_13 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_addr { + pub pfa: pf_addr__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_addr__bindgen_ty_1 { + pub v4: in_addr, + pub v6: in6_addr, + pub addr8: [u_int8_t; 16usize], + pub addr16: [u_int16_t; 8usize], + pub addr32: [u_int32_t; 4usize], +} +#[test] +fn bindgen_test_layout_pf_addr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_addr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).v4) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(v4) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).v6) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(v6) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(addr8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr16) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(addr16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr32) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr__bindgen_ty_1), + "::", + stringify!(addr32) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfa) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_addr), "::", stringify!(pfa)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_addr_wrap { + pub v: pf_addr_wrap__bindgen_ty_1, + pub p: pf_addr_wrap__bindgen_ty_2, + pub type_: u_int8_t, + pub iflags: u_int8_t, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_addr_wrap__bindgen_ty_1 { + pub a: pf_addr_wrap__bindgen_ty_1__bindgen_ty_1, + pub ifname: [::std::os::raw::c_char; 16usize], + pub tblname: [::std::os::raw::c_char; 32usize], + pub rtlabelname: [::std::os::raw::c_char; 32usize], + pub rtlabel: u_int32_t, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_addr_wrap__bindgen_ty_1__bindgen_ty_1 { + pub addr: pf_addr, + pub mask: pf_addr, +} +#[test] +fn bindgen_test_layout_pf_addr_wrap__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mask) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(mask) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_addr_wrap__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_addr_wrap__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_addr_wrap__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).a) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(a) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tblname) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(tblname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtlabelname) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(rtlabelname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtlabel) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_1), + "::", + stringify!(rtlabel) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_addr_wrap__bindgen_ty_2 { + pub dyn_: *mut pfi_dynaddr, + pub tbl: *mut pfr_ktable, + pub dyncnt: ::std::os::raw::c_int, + pub tblcnt: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_addr_wrap__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_addr_wrap__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_addr_wrap__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dyn_) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(dyn_) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tbl) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(tbl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dyncnt) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(dyncnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tblcnt) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_addr_wrap__bindgen_ty_2), + "::", + stringify!(tblcnt) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_addr_wrap() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(pf_addr_wrap)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_addr_wrap)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).v) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(v)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).p) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(p)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(type_)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).iflags) as usize - ptr as usize }, + 41usize, + concat!("Offset of field: ", stringify!(pf_addr_wrap), "::", stringify!(iflags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_uid { + pub uid: [uid_t; 2usize], + pub op: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_rule_uid() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(pf_rule_uid)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule_uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_uid), "::", stringify!(uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).op) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_rule_uid), "::", stringify!(op)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_gid { + pub gid: [uid_t; 2usize], + pub op: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_rule_gid() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(pf_rule_gid)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule_gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gid) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_gid), "::", stringify!(gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).op) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_rule_gid), "::", stringify!(op)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_rule_addr { + pub addr: pf_addr_wrap, + pub port: [u_int16_t; 2usize], + pub neg: u_int8_t, + pub port_op: u_int8_t, + pub weight: u_int16_t, +} +#[test] +fn bindgen_test_layout_pf_rule_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(pf_rule_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).neg) as usize - ptr as usize }, + 52usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(neg)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port_op) as usize - ptr as usize }, + 53usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(port_op)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).weight) as usize - ptr as usize }, + 54usize, + concat!("Offset of field: ", stringify!(pf_rule_addr), "::", stringify!(weight)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_threshold { + pub limit: u_int32_t, + pub seconds: u_int32_t, + pub count: u_int32_t, + pub last: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_threshold() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_threshold)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_threshold)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(limit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seconds) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(seconds)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).count) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(count)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).last) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pf_threshold), "::", stringify!(last)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_poolhashkey { + pub pfk: pf_poolhashkey__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_poolhashkey__bindgen_ty_1 { + pub key8: [u_int8_t; 16usize], + pub key16: [u_int16_t; 8usize], + pub key32: [u_int32_t; 4usize], +} +#[test] +fn bindgen_test_layout_pf_poolhashkey__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_poolhashkey__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_poolhashkey__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key8) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_poolhashkey__bindgen_ty_1), + "::", + stringify!(key8) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key16) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_poolhashkey__bindgen_ty_1), + "::", + stringify!(key16) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key32) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_poolhashkey__bindgen_ty_1), + "::", + stringify!(key32) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_poolhashkey() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_poolhashkey)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_poolhashkey)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfk) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_poolhashkey), "::", stringify!(pfk)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_pool { + pub addr: pf_addr_wrap, + pub key: pf_poolhashkey, + pub counter: pf_addr, + pub ifname: [::std::os::raw::c_char; 16usize], + pub kif: *mut pfi_kif, + pub tblidx: ::std::os::raw::c_int, + pub states: u_int64_t, + pub curweight: ::std::os::raw::c_int, + pub weight: u_int16_t, + pub proxy_port: [u_int16_t; 2usize], + pub port_op: u_int8_t, + pub opts: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_pool() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 136usize, + concat!("Size of: ", stringify!(pf_pool)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_pool)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(key)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).counter) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(counter)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tblidx) as usize - ptr as usize }, + 104usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(tblidx)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).curweight) as usize - ptr as usize }, + 120usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(curweight)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).weight) as usize - ptr as usize }, + 124usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(weight)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proxy_port) as usize - ptr as usize }, + 126usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(proxy_port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port_op) as usize - ptr as usize }, + 130usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(port_op)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).opts) as usize - ptr as usize }, + 131usize, + concat!("Offset of field: ", stringify!(pf_pool), "::", stringify!(opts)) + ); +} +pub type pf_osfp_t = u_int32_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_osfp_entry { + pub fp_entry: pf_osfp_entry__bindgen_ty_1, + pub fp_os: pf_osfp_t, + pub fp_enflags: ::std::os::raw::c_int, + pub fp_class_nm: [u_char; 32usize], + pub fp_version_nm: [u_char; 32usize], + pub fp_subtype_nm: [u_char; 32usize], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_osfp_entry__bindgen_ty_1 { + pub sle_next: *mut pf_osfp_entry, +} +#[test] +fn bindgen_test_layout_pf_osfp_entry__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_osfp_entry__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_osfp_entry__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_osfp_entry() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 112usize, + concat!("Size of: ", stringify!(pf_osfp_entry)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_osfp_entry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_entry) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_entry) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_os) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_osfp_entry), "::", stringify!(fp_os)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_enflags) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_enflags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_class_nm) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_class_nm) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_version_nm) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_version_nm) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_subtype_nm) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_entry), + "::", + stringify!(fp_subtype_nm) + ) + ); +} +pub type pf_tcpopts_t = u_int64_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_os_fingerprint { + pub fp_oses: pf_os_fingerprint_pf_osfp_enlist, + pub fp_tcpopts: pf_tcpopts_t, + pub fp_wsize: u_int16_t, + pub fp_psize: u_int16_t, + pub fp_mss: u_int16_t, + pub fp_flags: u_int16_t, + pub fp_optcnt: u_int8_t, + pub fp_wscale: u_int8_t, + pub fp_ttl: u_int8_t, + pub fp_next: pf_os_fingerprint__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_os_fingerprint_pf_osfp_enlist { + pub slh_first: *mut pf_osfp_entry, +} +#[test] +fn bindgen_test_layout_pf_os_fingerprint_pf_osfp_enlist() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_os_fingerprint_pf_osfp_enlist)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_os_fingerprint_pf_osfp_enlist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).slh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint_pf_osfp_enlist), + "::", + stringify!(slh_first) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_os_fingerprint__bindgen_ty_1 { + pub sle_next: *mut pf_os_fingerprint, +} +#[test] +fn bindgen_test_layout_pf_os_fingerprint__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_os_fingerprint__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_os_fingerprint__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_os_fingerprint() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pf_os_fingerprint)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_os_fingerprint)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_oses) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_oses) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_tcpopts) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_tcpopts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wsize) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_wsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_psize) as usize - ptr as usize }, + 18usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_psize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_mss) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_flags) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_optcnt) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_optcnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wscale) as usize - ptr as usize }, + 25usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_ttl) as usize - ptr as usize }, + 26usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_next) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_os_fingerprint), + "::", + stringify!(fp_next) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_osfp_ioctl { + pub fp_os: pf_osfp_entry, + pub fp_tcpopts: pf_tcpopts_t, + pub fp_wsize: u_int16_t, + pub fp_psize: u_int16_t, + pub fp_mss: u_int16_t, + pub fp_flags: u_int16_t, + pub fp_optcnt: u_int8_t, + pub fp_wscale: u_int8_t, + pub fp_ttl: u_int8_t, + pub fp_getnum: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_osfp_ioctl() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 136usize, + concat!("Size of: ", stringify!(pf_osfp_ioctl)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_osfp_ioctl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_os) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_osfp_ioctl), "::", stringify!(fp_os)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_tcpopts) as usize - ptr as usize }, + 112usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_tcpopts) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wsize) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_wsize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_psize) as usize - ptr as usize }, + 122usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_psize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_mss) as usize - ptr as usize }, + 124usize, + concat!("Offset of field: ", stringify!(pf_osfp_ioctl), "::", stringify!(fp_mss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_flags) as usize - ptr as usize }, + 126usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_optcnt) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_optcnt) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_wscale) as usize - ptr as usize }, + 129usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_ttl) as usize - ptr as usize }, + 130usize, + concat!("Offset of field: ", stringify!(pf_osfp_ioctl), "::", stringify!(fp_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_getnum) as usize - ptr as usize }, + 132usize, + concat!( + "Offset of field: ", + stringify!(pf_osfp_ioctl), + "::", + stringify!(fp_getnum) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_actions { + pub rtableid: ::std::os::raw::c_int, + pub qid: u_int16_t, + pub pqid: u_int16_t, + pub max_mss: u_int16_t, + pub flags: u_int16_t, + pub delay: u_int16_t, + pub log: u_int8_t, + pub set_tos: u_int8_t, + pub min_ttl: u_int8_t, + pub set_prio: [u_int8_t; 2usize], + pub pad: [u_int8_t; 1usize], +} +#[test] +fn bindgen_test_layout_pf_rule_actions() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pf_rule_actions)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule_actions)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtableid) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_actions), + "::", + stringify!(rtableid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pf_rule_actions), "::", stringify!(qid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pqid) as usize - ptr as usize }, + 6usize, + concat!("Offset of field: ", stringify!(pf_rule_actions), "::", stringify!(pqid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_mss) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_actions), + "::", + stringify!(max_mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 10usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_actions), + "::", + stringify!(flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).delay) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_actions), + "::", + stringify!(delay) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).log) as usize - ptr as usize }, + 14usize, + concat!("Offset of field: ", stringify!(pf_rule_actions), "::", stringify!(log)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_tos) as usize - ptr as usize }, + 15usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_actions), + "::", + stringify!(set_tos) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).min_ttl) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_actions), + "::", + stringify!(min_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_prio) as usize - ptr as usize }, + 17usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_actions), + "::", + stringify!(set_prio) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 19usize, + concat!("Offset of field: ", stringify!(pf_rule_actions), "::", stringify!(pad)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pf_rule_ptr { + pub ptr: *mut pf_rule, + pub nr: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_rule_ptr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_rule_ptr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule_ptr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_ptr), "::", stringify!(ptr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_ptr), "::", stringify!(nr)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_rule { + pub src: pf_rule_addr, + pub dst: pf_rule_addr, + pub skip: [pf_rule_ptr; 9usize], + pub label: [::std::os::raw::c_char; 64usize], + pub ifname: [::std::os::raw::c_char; 16usize], + pub rcv_ifname: [::std::os::raw::c_char; 16usize], + pub qname: [::std::os::raw::c_char; 64usize], + pub pqname: [::std::os::raw::c_char; 64usize], + pub tagname: [::std::os::raw::c_char; 64usize], + pub match_tagname: [::std::os::raw::c_char; 64usize], + pub overload_tblname: [::std::os::raw::c_char; 32usize], + pub entries: pf_rule__bindgen_ty_1, + pub nat: pf_pool, + pub rdr: pf_pool, + pub route: pf_pool, + pub pktrate: pf_threshold, + pub evaluations: u_int64_t, + pub packets: [u_int64_t; 2usize], + pub bytes: [u_int64_t; 2usize], + pub kif: *mut pfi_kif, + pub rcv_kif: *mut pfi_kif, + pub anchor: *mut pf_anchor, + pub overload_tbl: *mut pfr_ktable, + pub os_fingerprint: pf_osfp_t, + pub rtableid: ::std::os::raw::c_int, + pub onrdomain: ::std::os::raw::c_int, + pub timeout: [u_int32_t; 20usize], + pub states_cur: u_int32_t, + pub states_tot: u_int32_t, + pub max_states: u_int32_t, + pub src_nodes: u_int32_t, + pub max_src_nodes: u_int32_t, + pub max_src_states: u_int32_t, + pub max_src_conn: u_int32_t, + pub max_src_conn_rate: pf_rule__bindgen_ty_2, + pub qid: u_int32_t, + pub pqid: u_int32_t, + pub rt_listid: u_int32_t, + pub nr: u_int32_t, + pub prob: u_int32_t, + pub cuid: uid_t, + pub cpid: pid_t, + pub return_icmp: u_int16_t, + pub return_icmp6: u_int16_t, + pub max_mss: u_int16_t, + pub tag: u_int16_t, + pub match_tag: u_int16_t, + pub scrub_flags: u_int16_t, + pub delay: u_int16_t, + pub uid: pf_rule_uid, + pub gid: pf_rule_gid, + pub rule_flag: u_int32_t, + pub action: u_int8_t, + pub direction: u_int8_t, + pub log: u_int8_t, + pub logif: u_int8_t, + pub quick: u_int8_t, + pub ifnot: u_int8_t, + pub match_tag_not: u_int8_t, + pub keep_state: u_int8_t, + pub af: sa_family_t, + pub proto: u_int8_t, + pub type_: u_int16_t, + pub code: u_int16_t, + pub flags: u_int8_t, + pub flagset: u_int8_t, + pub min_ttl: u_int8_t, + pub allow_opts: u_int8_t, + pub rt: u_int8_t, + pub return_ttl: u_int8_t, + pub tos: u_int8_t, + pub set_tos: u_int8_t, + pub anchor_relative: u_int8_t, + pub anchor_wildcard: u_int8_t, + pub flush: u_int8_t, + pub prio: u_int8_t, + pub set_prio: [u_int8_t; 2usize], + pub naf: sa_family_t, + pub rcvifnot: u_int8_t, + pub divert: pf_rule__bindgen_ty_3, + pub exptime: time_t, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule__bindgen_ty_1 { + pub tqe_next: *mut pf_rule, + pub tqe_prev: *mut *mut pf_rule, +} +#[test] +fn bindgen_test_layout_pf_rule__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_rule__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule__bindgen_ty_2 { + pub limit: u_int32_t, + pub seconds: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_rule__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_rule__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_2), + "::", + stringify!(limit) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seconds) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_2), + "::", + stringify!(seconds) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_rule__bindgen_ty_3 { + pub addr: pf_addr, + pub port: u_int16_t, + pub type_: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_rule__bindgen_ty_3() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pf_rule__bindgen_ty_3)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_rule__bindgen_ty_3)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_3), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_3), + "::", + stringify!(port) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 18usize, + concat!( + "Offset of field: ", + stringify!(pf_rule__bindgen_ty_3), + "::", + stringify!(type_) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_rule() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1344usize, + concat!("Size of: ", stringify!(pf_rule)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(src)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dst) as usize - ptr as usize }, + 56usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(dst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).skip) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(skip)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).label) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(label)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 248usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rcv_ifname) as usize - ptr as usize }, + 264usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rcv_ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qname) as usize - ptr as usize }, + 280usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(qname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pqname) as usize - ptr as usize }, + 344usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(pqname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tagname) as usize - ptr as usize }, + 408usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(tagname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_tagname) as usize - ptr as usize }, + 472usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(match_tagname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).overload_tblname) as usize - ptr as usize }, + 536usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(overload_tblname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 568usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nat) as usize - ptr as usize }, + 584usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(nat)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdr) as usize - ptr as usize }, + 720usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rdr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).route) as usize - ptr as usize }, + 856usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(route)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pktrate) as usize - ptr as usize }, + 992usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(pktrate)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).evaluations) as usize - ptr as usize }, + 1008usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(evaluations)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 1016usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 1032usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 1048usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rcv_kif) as usize - ptr as usize }, + 1056usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rcv_kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 1064usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).overload_tbl) as usize - ptr as usize }, + 1072usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(overload_tbl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).os_fingerprint) as usize - ptr as usize }, + 1080usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(os_fingerprint) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtableid) as usize - ptr as usize }, + 1084usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rtableid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).onrdomain) as usize - ptr as usize }, + 1088usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(onrdomain)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 1092usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(timeout)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states_cur) as usize - ptr as usize }, + 1172usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(states_cur)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states_tot) as usize - ptr as usize }, + 1176usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(states_tot)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_states) as usize - ptr as usize }, + 1180usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(max_states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src_nodes) as usize - ptr as usize }, + 1184usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(src_nodes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_nodes) as usize - ptr as usize }, + 1188usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(max_src_nodes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_states) as usize - ptr as usize }, + 1192usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(max_src_states) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_conn) as usize - ptr as usize }, + 1196usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(max_src_conn)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_src_conn_rate) as usize - ptr as usize }, + 1200usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(max_src_conn_rate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 1208usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(qid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pqid) as usize - ptr as usize }, + 1212usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(pqid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_listid) as usize - ptr as usize }, + 1216usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rt_listid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 1220usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).prob) as usize - ptr as usize }, + 1224usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(prob)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cuid) as usize - ptr as usize }, + 1228usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(cuid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).cpid) as usize - ptr as usize }, + 1232usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(cpid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).return_icmp) as usize - ptr as usize }, + 1236usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(return_icmp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).return_icmp6) as usize - ptr as usize }, + 1238usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(return_icmp6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_mss) as usize - ptr as usize }, + 1240usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(max_mss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tag) as usize - ptr as usize }, + 1242usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_tag) as usize - ptr as usize }, + 1244usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(match_tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub_flags) as usize - ptr as usize }, + 1246usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(scrub_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).delay) as usize - ptr as usize }, + 1248usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(delay)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).uid) as usize - ptr as usize }, + 1252usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(uid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gid) as usize - ptr as usize }, + 1264usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(gid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule_flag) as usize - ptr as usize }, + 1276usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rule_flag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 1280usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(action)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 1281usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(direction)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).log) as usize - ptr as usize }, + 1282usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(log)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).logif) as usize - ptr as usize }, + 1283usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(logif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).quick) as usize - ptr as usize }, + 1284usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(quick)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifnot) as usize - ptr as usize }, + 1285usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(ifnot)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_tag_not) as usize - ptr as usize }, + 1286usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(match_tag_not) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).keep_state) as usize - ptr as usize }, + 1287usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(keep_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 1288usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 1289usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(proto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 1290usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(type_)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).code) as usize - ptr as usize }, + 1292usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(code)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 1294usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flagset) as usize - ptr as usize }, + 1295usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(flagset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).min_ttl) as usize - ptr as usize }, + 1296usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(min_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).allow_opts) as usize - ptr as usize }, + 1297usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(allow_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt) as usize - ptr as usize }, + 1298usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).return_ttl) as usize - ptr as usize }, + 1299usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(return_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tos) as usize - ptr as usize }, + 1300usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(tos)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_tos) as usize - ptr as usize }, + 1301usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(set_tos)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor_relative) as usize - ptr as usize }, + 1302usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(anchor_relative) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor_wildcard) as usize - ptr as usize }, + 1303usize, + concat!( + "Offset of field: ", + stringify!(pf_rule), + "::", + stringify!(anchor_wildcard) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flush) as usize - ptr as usize }, + 1304usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(flush)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).prio) as usize - ptr as usize }, + 1305usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(prio)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_prio) as usize - ptr as usize }, + 1306usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(set_prio)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).naf) as usize - ptr as usize }, + 1308usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(naf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rcvifnot) as usize - ptr as usize }, + 1309usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(rcvifnot)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).divert) as usize - ptr as usize }, + 1312usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(divert)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).exptime) as usize - ptr as usize }, + 1336usize, + concat!("Offset of field: ", stringify!(pf_rule), "::", stringify!(exptime)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_item { + pub entry: pf_rule_item__bindgen_ty_1, + pub r: *mut pf_rule, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_item__bindgen_ty_1 { + pub sle_next: *mut pf_rule_item, +} +#[test] +fn bindgen_test_layout_pf_rule_item__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_rule_item__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule_item__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_item__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_rule_item() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_rule_item)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule_item)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_rule_item), "::", stringify!(entry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).r) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_rule_item), "::", stringify!(r)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rule_slist { + pub slh_first: *mut pf_rule_item, +} +#[test] +fn bindgen_test_layout_pf_rule_slist() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_rule_slist)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rule_slist)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).slh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rule_slist), + "::", + stringify!(slh_first) + ) + ); +} +pub const pf_sn_types_PF_SN_NONE: pf_sn_types = 0; +pub const pf_sn_types_PF_SN_NAT: pf_sn_types = 1; +pub const pf_sn_types_PF_SN_RDR: pf_sn_types = 2; +pub const pf_sn_types_PF_SN_ROUTE: pf_sn_types = 3; +pub const pf_sn_types_PF_SN_MAX: pf_sn_types = 4; +pub type pf_sn_types = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_src_node { + pub entry: pf_src_node__bindgen_ty_1, + pub addr: pf_addr, + pub raddr: pf_addr, + pub rule: pf_rule_ptr, + pub kif: *mut pfi_kif, + pub bytes: [u_int64_t; 2usize], + pub packets: [u_int64_t; 2usize], + pub states: u_int32_t, + pub conn: u_int32_t, + pub conn_rate: pf_threshold, + pub creation: i32, + pub expire: i32, + pub af: sa_family_t, + pub naf: sa_family_t, + pub type_: u_int8_t, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_src_node__bindgen_ty_1 { + pub rbe_left: *mut pf_src_node, + pub rbe_right: *mut pf_src_node, + pub rbe_parent: *mut pf_src_node, + pub rbe_color: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_src_node__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_src_node__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_src_node__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_left) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node__bindgen_ty_1), + "::", + stringify!(rbe_left) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_right) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node__bindgen_ty_1), + "::", + stringify!(rbe_right) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_parent) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node__bindgen_ty_1), + "::", + stringify!(rbe_parent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_color) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node__bindgen_ty_1), + "::", + stringify!(rbe_color) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_src_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 152usize, + concat!("Size of: ", stringify!(pf_src_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_src_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(entry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).raddr) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(raddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).conn) as usize - ptr as usize }, + 116usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(conn)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).conn_rate) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(pf_src_node), + "::", + stringify!(conn_rate) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creation) as usize - ptr as usize }, + 136usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(creation)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).expire) as usize - ptr as usize }, + 140usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(expire)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 144usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).naf) as usize - ptr as usize }, + 145usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(naf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 146usize, + concat!("Offset of field: ", stringify!(pf_src_node), "::", stringify!(type_)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_sn_item { + pub next: pf_sn_item__bindgen_ty_1, + pub sn: *mut pf_src_node, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_sn_item__bindgen_ty_1 { + pub sle_next: *mut pf_sn_item, +} +#[test] +fn bindgen_test_layout_pf_sn_item__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_sn_item__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_sn_item__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_sn_item__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_sn_item() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_sn_item)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_sn_item)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).next) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_sn_item), "::", stringify!(next)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sn) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_sn_item), "::", stringify!(sn)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_sn_head { + pub slh_first: *mut pf_sn_item, +} +#[test] +fn bindgen_test_layout_pf_sn_head() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_sn_head)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_sn_head)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).slh_first) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_sn_head), "::", stringify!(slh_first)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_scrub { + pub pfss_last: timeval, + pub pfss_tsecr: u_int32_t, + pub pfss_tsval: u_int32_t, + pub pfss_tsval0: u_int32_t, + pub pfss_flags: u_int16_t, + pub pfss_ttl: u_int8_t, + pub pad: u_int8_t, + pub pfss_ts_mod: u_int32_t, +} +#[test] +fn bindgen_test_layout_pf_state_scrub() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pf_state_scrub)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_scrub)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_last) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_last) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_tsecr) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_tsecr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_tsval) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_tsval) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_tsval0) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_tsval0) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_flags) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ttl) as usize - ptr as usize }, + 30usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 31usize, + concat!("Offset of field: ", stringify!(pf_state_scrub), "::", stringify!(pad)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ts_mod) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_state_scrub), + "::", + stringify!(pfss_ts_mod) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_state_host { + pub addr: pf_addr, + pub port: u_int16_t, + pub pad: u_int16_t, +} +#[test] +fn bindgen_test_layout_pf_state_host() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pf_state_host)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_state_host)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_host), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_state_host), "::", stringify!(port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(pf_state_host), "::", stringify!(pad)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_peer { + pub scrub: *mut pf_state_scrub, + pub seqlo: u_int32_t, + pub seqhi: u_int32_t, + pub seqdiff: u_int32_t, + pub max_win: u_int16_t, + pub mss: u_int16_t, + pub state: u_int8_t, + pub wscale: u_int8_t, + pub tcp_est: u_int8_t, + pub pad: [u_int8_t; 1usize], +} +#[test] +fn bindgen_test_layout_pf_state_peer() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_state_peer)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_peer)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(scrub)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqlo) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(seqlo)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqhi) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(seqhi)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqdiff) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer), + "::", + stringify!(seqdiff) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_win) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer), + "::", + stringify!(max_win) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mss) as usize - ptr as usize }, + 22usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(mss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).wscale) as usize - ptr as usize }, + 25usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(wscale)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tcp_est) as usize - ptr as usize }, + 26usize, + concat!( + "Offset of field: ", + stringify!(pf_state_peer), + "::", + stringify!(tcp_est) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 27usize, + concat!("Offset of field: ", stringify!(pf_state_peer), "::", stringify!(pad)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_queue { + pub tqh_first: *mut pf_state, + pub tqh_last: *mut *mut pf_state, +} +#[test] +fn bindgen_test_layout_pf_state_queue() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_state_queue)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_queue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_queue), + "::", + stringify!(tqh_first) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_state_queue), + "::", + stringify!(tqh_last) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_state_key_cmp { + pub addr: [pf_addr; 2usize], + pub port: [u_int16_t; 2usize], + pub rdomain: u_int16_t, + pub hash: u_int16_t, + pub af: sa_family_t, + pub proto: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_state_key_cmp() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 44usize, + concat!("Size of: ", stringify!(pf_state_key_cmp)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_state_key_cmp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_cmp), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_cmp), + "::", + stringify!(port) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdomain) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_cmp), + "::", + stringify!(rdomain) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hash) as usize - ptr as usize }, + 38usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_cmp), + "::", + stringify!(hash) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pf_state_key_cmp), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 41usize, + concat!( + "Offset of field: ", + stringify!(pf_state_key_cmp), + "::", + stringify!(proto) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_cmp { + pub id: u_int64_t, + pub creatorid: u_int32_t, + pub direction: u_int8_t, + pub pad: [u_int8_t; 3usize], +} +#[test] +fn bindgen_test_layout_pf_state_cmp() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_state_cmp)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_cmp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).id) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_state_cmp), "::", stringify!(id)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creatorid) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_state_cmp), + "::", + stringify!(creatorid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pf_state_cmp), + "::", + stringify!(direction) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 13usize, + concat!("Offset of field: ", stringify!(pf_state_cmp), "::", stringify!(pad)) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct pfsync_state_scrub { + pub pfss_flags: u_int16_t, + pub pfss_ttl: u_int8_t, + pub scrub_flag: u_int8_t, + pub pfss_ts_mod: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfsync_state_scrub() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfsync_state_scrub)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_scrub)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_flags) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(pfss_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ttl) as usize - ptr as usize }, + 2usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(pfss_ttl) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub_flag) as usize - ptr as usize }, + 3usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(scrub_flag) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfss_ts_mod) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_scrub), + "::", + stringify!(pfss_ts_mod) + ) + ); +} +#[repr(C, packed)] +#[derive(Debug, Copy, Clone)] +pub struct pfsync_state_peer { + pub scrub: pfsync_state_scrub, + pub seqlo: u_int32_t, + pub seqhi: u_int32_t, + pub seqdiff: u_int32_t, + pub max_win: u_int16_t, + pub mss: u_int16_t, + pub state: u_int8_t, + pub wscale: u_int8_t, + pub pad: [u_int8_t; 6usize], +} +#[test] +fn bindgen_test_layout_pfsync_state_peer() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pfsync_state_peer)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state_peer)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scrub) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(scrub) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqlo) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(seqlo) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqhi) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(seqhi) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seqdiff) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(seqdiff) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_win) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(max_win) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).mss) as usize - ptr as usize }, + 22usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(mss) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(state) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).wscale) as usize - ptr as usize }, + 25usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(wscale) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 26usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_peer), + "::", + stringify!(pad) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfsync_state_key { + pub addr: [pf_addr; 2usize], + pub port: [u_int16_t; 2usize], + pub rdomain: u_int16_t, + pub af: sa_family_t, + pub pad: u_int8_t, +} +#[test] +fn bindgen_test_layout_pfsync_state_key() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pfsync_state_key)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfsync_state_key)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_key), + "::", + stringify!(addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_key), + "::", + stringify!(port) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdomain) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state_key), + "::", + stringify!(rdomain) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 38usize, + concat!("Offset of field: ", stringify!(pfsync_state_key), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 39usize, + concat!("Offset of field: ", stringify!(pfsync_state_key), "::", stringify!(pad)) + ); +} +#[repr(C, packed)] +#[derive(Copy, Clone)] +pub struct pfsync_state { + pub id: u_int64_t, + pub ifname: [::std::os::raw::c_char; 16usize], + pub key: [pfsync_state_key; 2usize], + pub src: pfsync_state_peer, + pub dst: pfsync_state_peer, + pub rt_addr: pf_addr, + pub rule: u_int32_t, + pub anchor: u_int32_t, + pub nat_rule: u_int32_t, + pub creation: u_int32_t, + pub expire: u_int32_t, + pub packets: [[u_int32_t; 2usize]; 2usize], + pub bytes: [[u_int32_t; 2usize]; 2usize], + pub creatorid: u_int32_t, + pub rtableid: [i32; 2usize], + pub max_mss: u_int16_t, + pub af: sa_family_t, + pub proto: u_int8_t, + pub direction: u_int8_t, + pub log: u_int8_t, + pub rt: u_int8_t, + pub timeout: u_int8_t, + pub sync_flags: u_int8_t, + pub updates: u_int8_t, + pub min_ttl: u_int8_t, + pub set_tos: u_int8_t, + pub state_flags: u_int16_t, + pub set_prio: [u_int8_t; 2usize], +} +#[test] +fn bindgen_test_layout_pfsync_state() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 264usize, + concat!("Size of: ", stringify!(pfsync_state)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfsync_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).id) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(id)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).key) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(key)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src) as usize - ptr as usize }, + 104usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(src)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dst) as usize - ptr as usize }, + 136usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(dst)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt_addr) as usize - ptr as usize }, + 168usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(rt_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 188usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nat_rule) as usize - ptr as usize }, + 192usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(nat_rule) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creation) as usize - ptr as usize }, + 196usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(creation) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).expire) as usize - ptr as usize }, + 200usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(expire)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).packets) as usize - ptr as usize }, + 204usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bytes) as usize - ptr as usize }, + 220usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).creatorid) as usize - ptr as usize }, + 236usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(creatorid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtableid) as usize - ptr as usize }, + 240usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(rtableid) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).max_mss) as usize - ptr as usize }, + 248usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(max_mss)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 250usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 251usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(proto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 252usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(direction) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).log) as usize - ptr as usize }, + 253usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(log)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rt) as usize - ptr as usize }, + 254usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(rt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 255usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(timeout)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sync_flags) as usize - ptr as usize }, + 256usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(sync_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).updates) as usize - ptr as usize }, + 257usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(updates)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).min_ttl) as usize - ptr as usize }, + 258usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(min_ttl)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_tos) as usize - ptr as usize }, + 259usize, + concat!("Offset of field: ", stringify!(pfsync_state), "::", stringify!(set_tos)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state_flags) as usize - ptr as usize }, + 260usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(state_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).set_prio) as usize - ptr as usize }, + 262usize, + concat!( + "Offset of field: ", + stringify!(pfsync_state), + "::", + stringify!(set_prio) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_rulequeue { + pub tqh_first: *mut pf_rule, + pub tqh_last: *mut *mut pf_rule, +} +#[test] +fn bindgen_test_layout_pf_rulequeue() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_rulequeue)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_rulequeue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_rulequeue), + "::", + stringify!(tqh_first) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_rulequeue), + "::", + stringify!(tqh_last) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ruleset { + pub rules: pf_ruleset__bindgen_ty_1, + pub anchor: *mut pf_anchor, + pub tticket: u_int32_t, + pub tables: ::std::os::raw::c_int, + pub topen: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ruleset__bindgen_ty_1 { + pub queues: [pf_rulequeue; 2usize], + pub active: pf_ruleset__bindgen_ty_1__bindgen_ty_1, + pub inactive: pf_ruleset__bindgen_ty_1__bindgen_ty_1, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_ruleset__bindgen_ty_1__bindgen_ty_1 { + pub ptr: *mut pf_rulequeue, + pub rcount: u_int32_t, + pub version: u_int32_t, + pub open: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_ruleset__bindgen_ty_1__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ptr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(ptr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rcount) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(rcount) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(version) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).open) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(open) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_ruleset__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 80usize, + concat!("Size of: ", stringify!(pf_ruleset__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ruleset__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).queues) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1), + "::", + stringify!(queues) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).active) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1), + "::", + stringify!(active) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).inactive) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(pf_ruleset__bindgen_ty_1), + "::", + stringify!(inactive) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_ruleset() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 104usize, + concat!("Size of: ", stringify!(pf_ruleset)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rules) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(rules)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tticket) as usize - ptr as usize }, + 88usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(tticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tables) as usize - ptr as usize }, + 92usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(tables)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).topen) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(pf_ruleset), "::", stringify!(topen)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor_global { + pub rbh_root: *mut pf_anchor, +} +#[test] +fn bindgen_test_layout_pf_anchor_global() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_anchor_global)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor_global)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor_global), + "::", + stringify!(rbh_root) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor_node { + pub rbh_root: *mut pf_anchor, +} +#[test] +fn bindgen_test_layout_pf_anchor_node() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_anchor_node)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor_node), + "::", + stringify!(rbh_root) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor { + pub entry_global: pf_anchor__bindgen_ty_1, + pub entry_node: pf_anchor__bindgen_ty_2, + pub parent: *mut pf_anchor, + pub children: pf_anchor_node, + pub name: [::std::os::raw::c_char; 64usize], + pub path: [::std::os::raw::c_char; 1024usize], + pub ruleset: pf_ruleset, + pub refcnt: ::std::os::raw::c_int, + pub match_: ::std::os::raw::c_int, + pub ref_: refcnt, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor__bindgen_ty_1 { + pub rbe_left: *mut pf_anchor, + pub rbe_right: *mut pf_anchor, + pub rbe_parent: *mut pf_anchor, + pub rbe_color: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_anchor__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_anchor__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_left) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_1), + "::", + stringify!(rbe_left) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_right) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_1), + "::", + stringify!(rbe_right) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_parent) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_1), + "::", + stringify!(rbe_parent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_color) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_1), + "::", + stringify!(rbe_color) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_anchor__bindgen_ty_2 { + pub rbe_left: *mut pf_anchor, + pub rbe_right: *mut pf_anchor, + pub rbe_parent: *mut pf_anchor, + pub rbe_color: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pf_anchor__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pf_anchor__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_left) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_2), + "::", + stringify!(rbe_left) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_right) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_2), + "::", + stringify!(rbe_right) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_parent) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_2), + "::", + stringify!(rbe_parent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_color) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor__bindgen_ty_2), + "::", + stringify!(rbe_color) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_anchor() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1288usize, + concat!("Size of: ", stringify!(pf_anchor)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry_global) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_anchor), + "::", + stringify!(entry_global) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entry_node) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(entry_node)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).children) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(children)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).path) as usize - ptr as usize }, + 144usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(path)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ruleset) as usize - ptr as usize }, + 1168usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).refcnt) as usize - ptr as usize }, + 1272usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(refcnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).match_) as usize - ptr as usize }, + 1276usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(match_)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ref_) as usize - ptr as usize }, + 1280usize, + concat!("Offset of field: ", stringify!(pf_anchor), "::", stringify!(ref_)) + ); +} +extern "C" { + pub fn pf_anchor_global_RB_INSERT_COLOR(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor); +} +extern "C" { + pub fn pf_anchor_global_RB_REMOVE_COLOR(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor, arg3: *mut pf_anchor); +} +extern "C" { + pub fn pf_anchor_global_RB_REMOVE(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_INSERT(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_FIND(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_NFIND(arg1: *mut pf_anchor_global, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_NEXT(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_PREV(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_global_RB_MINMAX(arg1: *mut pf_anchor_global, arg2: ::std::os::raw::c_int) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_INSERT_COLOR(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor); +} +extern "C" { + pub fn pf_anchor_node_RB_REMOVE_COLOR(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor, arg3: *mut pf_anchor); +} +extern "C" { + pub fn pf_anchor_node_RB_REMOVE(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_INSERT(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_FIND(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_NFIND(arg1: *mut pf_anchor_node, arg2: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_NEXT(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_PREV(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_anchor_node_RB_MINMAX(arg1: *mut pf_anchor_node, arg2: ::std::os::raw::c_int) -> *mut pf_anchor; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_table { + pub pfrt_anchor: [::std::os::raw::c_char; 1024usize], + pub pfrt_name: [::std::os::raw::c_char; 32usize], + pub pfrt_flags: u_int32_t, + pub pfrt_fback: u_int8_t, +} +#[test] +fn bindgen_test_layout_pfr_table() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1064usize, + concat!("Size of: ", stringify!(pfr_table)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfr_table)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_anchor) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_table), + "::", + stringify!(pfrt_anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_name) as usize - ptr as usize }, + 1024usize, + concat!("Offset of field: ", stringify!(pfr_table), "::", stringify!(pfrt_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_flags) as usize - ptr as usize }, + 1056usize, + concat!("Offset of field: ", stringify!(pfr_table), "::", stringify!(pfrt_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrt_fback) as usize - ptr as usize }, + 1060usize, + concat!("Offset of field: ", stringify!(pfr_table), "::", stringify!(pfrt_fback)) + ); +} +pub const PFR_FB_NONE: _bindgen_ty_14 = 0; +pub const PFR_FB_MATCH: _bindgen_ty_14 = 1; +pub const PFR_FB_ADDED: _bindgen_ty_14 = 2; +pub const PFR_FB_DELETED: _bindgen_ty_14 = 3; +pub const PFR_FB_CHANGED: _bindgen_ty_14 = 4; +pub const PFR_FB_CLEARED: _bindgen_ty_14 = 5; +pub const PFR_FB_DUPLICATE: _bindgen_ty_14 = 6; +pub const PFR_FB_NOTMATCH: _bindgen_ty_14 = 7; +pub const PFR_FB_CONFLICT: _bindgen_ty_14 = 8; +pub const PFR_FB_NOCOUNT: _bindgen_ty_14 = 9; +pub const PFR_FB_MAX: _bindgen_ty_14 = 10; +pub type _bindgen_ty_14 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_addr { + pub pfra_u: pfr_addr__bindgen_ty_1, + pub pfra_ifname: [::std::os::raw::c_char; 16usize], + pub pfra_states: u_int32_t, + pub pfra_weight: u_int16_t, + pub pfra_af: u_int8_t, + pub pfra_net: u_int8_t, + pub pfra_not: u_int8_t, + pub pfra_fback: u_int8_t, + pub pfra_type: u_int8_t, + pub pad: [u_int8_t; 7usize], +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfr_addr__bindgen_ty_1 { + pub _pfra_ip4addr: in_addr, + pub _pfra_ip6addr: in6_addr, +} +#[test] +fn bindgen_test_layout_pfr_addr__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfr_addr__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfr_addr__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfra_ip4addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_addr__bindgen_ty_1), + "::", + stringify!(_pfra_ip4addr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfra_ip6addr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_addr__bindgen_ty_1), + "::", + stringify!(_pfra_ip6addr) + ) + ); +} +#[test] +fn bindgen_test_layout_pfr_addr() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 52usize, + concat!("Size of: ", stringify!(pfr_addr)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfr_addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_u) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_u)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_ifname) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_states) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_weight) as usize - ptr as usize }, + 36usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_weight)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_af) as usize - ptr as usize }, + 38usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_net) as usize - ptr as usize }, + 39usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_net)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_not) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_not)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_fback) as usize - ptr as usize }, + 41usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_fback)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfra_type) as usize - ptr as usize }, + 42usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pfra_type)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 43usize, + concat!("Offset of field: ", stringify!(pfr_addr), "::", stringify!(pad)) + ); +} +pub const PFR_DIR_IN: _bindgen_ty_15 = 0; +pub const PFR_DIR_OUT: _bindgen_ty_15 = 1; +pub const PFR_DIR_MAX: _bindgen_ty_15 = 2; +pub type _bindgen_ty_15 = ::std::os::raw::c_uint; +pub const PFR_OP_BLOCK: _bindgen_ty_16 = 0; +pub const PFR_OP_MATCH: _bindgen_ty_16 = 1; +pub const PFR_OP_PASS: _bindgen_ty_16 = 2; +pub const PFR_OP_ADDR_MAX: _bindgen_ty_16 = 3; +pub const PFR_OP_TABLE_MAX: _bindgen_ty_16 = 4; +pub type _bindgen_ty_16 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_astats { + pub pfras_a: pfr_addr, + pub pfras_packets: [[u_int64_t; 3usize]; 2usize], + pub pfras_bytes: [[u_int64_t; 3usize]; 2usize], + pub pfras_tzero: time_t, +} +#[test] +fn bindgen_test_layout_pfr_astats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 160usize, + concat!("Size of: ", stringify!(pfr_astats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_astats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_a) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_astats), "::", stringify!(pfras_a)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_packets) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(pfr_astats), + "::", + stringify!(pfras_packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_bytes) as usize - ptr as usize }, + 104usize, + concat!( + "Offset of field: ", + stringify!(pfr_astats), + "::", + stringify!(pfras_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfras_tzero) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(pfr_astats), + "::", + stringify!(pfras_tzero) + ) + ); +} +pub const PFR_REFCNT_RULE: _bindgen_ty_17 = 0; +pub const PFR_REFCNT_ANCHOR: _bindgen_ty_17 = 1; +pub const PFR_REFCNT_MAX: _bindgen_ty_17 = 2; +pub type _bindgen_ty_17 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_tstats { + pub pfrts_t: pfr_table, + pub pfrts_packets: [[u_int64_t; 4usize]; 2usize], + pub pfrts_bytes: [[u_int64_t; 4usize]; 2usize], + pub pfrts_match: u_int64_t, + pub pfrts_nomatch: u_int64_t, + pub pfrts_tzero: time_t, + pub pfrts_cnt: ::std::os::raw::c_int, + pub pfrts_refcnt: [::std::os::raw::c_int; 2usize], +} +#[test] +fn bindgen_test_layout_pfr_tstats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1232usize, + concat!("Size of: ", stringify!(pfr_tstats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_tstats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_t) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_tstats), "::", stringify!(pfrts_t)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_packets) as usize - ptr as usize }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_bytes) as usize - ptr as usize }, + 1128usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_match) as usize - ptr as usize }, + 1192usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_match) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_nomatch) as usize - ptr as usize }, + 1200usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_nomatch) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_tzero) as usize - ptr as usize }, + 1208usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_tzero) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_cnt) as usize - ptr as usize }, + 1216usize, + concat!("Offset of field: ", stringify!(pfr_tstats), "::", stringify!(pfrts_cnt)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrts_refcnt) as usize - ptr as usize }, + 1220usize, + concat!( + "Offset of field: ", + stringify!(pfr_tstats), + "::", + stringify!(pfrts_refcnt) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_kcounters { + pub pfrkc_packets: [[u_int64_t; 3usize]; 2usize], + pub pfrkc_bytes: [[u_int64_t; 3usize]; 2usize], + pub states: u_int64_t, +} +#[test] +fn bindgen_test_layout_pfr_kcounters() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 104usize, + concat!("Size of: ", stringify!(pfr_kcounters)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkc_packets) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_kcounters), + "::", + stringify!(pfrkc_packets) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkc_bytes) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(pfr_kcounters), + "::", + stringify!(pfrkc_bytes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 96usize, + concat!("Offset of field: ", stringify!(pfr_kcounters), "::", stringify!(states)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfsockaddr_union { + pub sa: sockaddr, + pub sin: sockaddr_in, + pub sin6: sockaddr_in6, +} +#[test] +fn bindgen_test_layout_pfsockaddr_union() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 28usize, + concat!("Size of: ", stringify!(pfsockaddr_union)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfsockaddr_union)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sa) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfsockaddr_union), "::", stringify!(sa)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfsockaddr_union), "::", stringify!(sin)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sin6) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfsockaddr_union), + "::", + stringify!(sin6) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_kentryworkq { + pub slh_first: *mut pfr_kentry, +} +#[test] +fn bindgen_test_layout_pfr_kentryworkq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfr_kentryworkq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kentryworkq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).slh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentryworkq), + "::", + stringify!(slh_first) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct _pfr_kentry { + pub _pfrke_node: [radix_node; 2usize], + pub _pfrke_sa: pfsockaddr_union, + pub _pfrke_workq: _pfr_kentry__bindgen_ty_1, + pub _pfrke_ioq: _pfr_kentry__bindgen_ty_2, + pub _pfrke_counters: *mut pfr_kcounters, + pub _pfrke_tzero: time_t, + pub _pfrke_af: u_int8_t, + pub _pfrke_net: u_int8_t, + pub _pfrke_flags: u_int8_t, + pub _pfrke_type: u_int8_t, + pub _pfrke_fb: u_int8_t, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _pfr_kentry__bindgen_ty_1 { + pub sle_next: *mut pfr_kentry, +} +#[test] +fn bindgen_test_layout__pfr_kentry__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit<_pfr_kentry__bindgen_ty_1> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_pfr_kentry__bindgen_ty_1>(), + 8usize, + concat!("Size of: ", stringify!(_pfr_kentry__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::<_pfr_kentry__bindgen_ty_1>(), + 8usize, + concat!("Alignment of ", stringify!(_pfr_kentry__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry__bindgen_ty_1), + "::", + stringify!(sle_next) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct _pfr_kentry__bindgen_ty_2 { + pub sle_next: *mut pfr_kentry, +} +#[test] +fn bindgen_test_layout__pfr_kentry__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit<_pfr_kentry__bindgen_ty_2> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_pfr_kentry__bindgen_ty_2>(), + 8usize, + concat!("Size of: ", stringify!(_pfr_kentry__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::<_pfr_kentry__bindgen_ty_2>(), + 8usize, + concat!("Alignment of ", stringify!(_pfr_kentry__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry__bindgen_ty_2), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout__pfr_kentry() { + const UNINIT: ::std::mem::MaybeUninit<_pfr_kentry> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<_pfr_kentry>(), + 168usize, + concat!("Size of: ", stringify!(_pfr_kentry)) + ); + assert_eq!( + ::std::mem::align_of::<_pfr_kentry>(), + 8usize, + concat!("Alignment of ", stringify!(_pfr_kentry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_node) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_node) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_sa) as usize - ptr as usize }, + 96usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_sa) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_workq) as usize - ptr as usize }, + 128usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_workq) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_ioq) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_ioq) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_counters) as usize - ptr as usize }, + 144usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_counters) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_tzero) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_tzero) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_af) as usize - ptr as usize }, + 160usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_af) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_net) as usize - ptr as usize }, + 161usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_net) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_flags) as usize - ptr as usize }, + 162usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_type) as usize - ptr as usize }, + 163usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_type) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._pfrke_fb) as usize - ptr as usize }, + 164usize, + concat!( + "Offset of field: ", + stringify!(_pfr_kentry), + "::", + stringify!(_pfrke_fb) + ) + ); +} +pub const PFRKE_PLAIN: _bindgen_ty_18 = 0; +pub const PFRKE_ROUTE: _bindgen_ty_18 = 1; +pub const PFRKE_COST: _bindgen_ty_18 = 2; +pub const PFRKE_MAX: _bindgen_ty_18 = 3; +pub type _bindgen_ty_18 = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_kentry { + pub u: pfr_kentry__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfr_kentry__bindgen_ty_1 { + pub _ke: _pfr_kentry, +} +#[test] +fn bindgen_test_layout_pfr_kentry__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 168usize, + concat!("Size of: ", stringify!(pfr_kentry__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kentry__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ke) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentry__bindgen_ty_1), + "::", + stringify!(_ke) + ) + ); +} +#[test] +fn bindgen_test_layout_pfr_kentry() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 168usize, + concat!("Size of: ", stringify!(pfr_kentry)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kentry)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).u) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_kentry), "::", stringify!(u)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_kentry_route { + pub u: pfr_kentry_route__bindgen_ty_1, + pub kif: *mut pfi_kif, + pub ifname: [::std::os::raw::c_char; 16usize], +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfr_kentry_route__bindgen_ty_1 { + pub _ke: _pfr_kentry, +} +#[test] +fn bindgen_test_layout_pfr_kentry_route__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 168usize, + concat!("Size of: ", stringify!(pfr_kentry_route__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kentry_route__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ke) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentry_route__bindgen_ty_1), + "::", + stringify!(_ke) + ) + ); +} +#[test] +fn bindgen_test_layout_pfr_kentry_route() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 192usize, + concat!("Size of: ", stringify!(pfr_kentry_route)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kentry_route)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).u) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_kentry_route), "::", stringify!(u)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 168usize, + concat!("Offset of field: ", stringify!(pfr_kentry_route), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 176usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentry_route), + "::", + stringify!(ifname) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_kentry_cost { + pub u: pfr_kentry_cost__bindgen_ty_1, + pub kif: *mut pfi_kif, + pub ifname: [::std::os::raw::c_char; 16usize], + pub weight: u_int16_t, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfr_kentry_cost__bindgen_ty_1 { + pub _ke: _pfr_kentry, +} +#[test] +fn bindgen_test_layout_pfr_kentry_cost__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 168usize, + concat!("Size of: ", stringify!(pfr_kentry_cost__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kentry_cost__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ke) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentry_cost__bindgen_ty_1), + "::", + stringify!(_ke) + ) + ); +} +#[test] +fn bindgen_test_layout_pfr_kentry_cost() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 200usize, + concat!("Size of: ", stringify!(pfr_kentry_cost)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kentry_cost)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).u) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_kentry_cost), "::", stringify!(u)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 168usize, + concat!("Offset of field: ", stringify!(pfr_kentry_cost), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 176usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentry_cost), + "::", + stringify!(ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).weight) as usize - ptr as usize }, + 192usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentry_cost), + "::", + stringify!(weight) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfr_kentry_all { + pub u: pfr_kentry_all__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfr_kentry_all__bindgen_ty_1 { + pub _ke: _pfr_kentry, + pub kr: pfr_kentry_route, + pub kc: pfr_kentry_cost, +} +#[test] +fn bindgen_test_layout_pfr_kentry_all__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 200usize, + concat!("Size of: ", stringify!(pfr_kentry_all__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kentry_all__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr)._ke) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentry_all__bindgen_ty_1), + "::", + stringify!(_ke) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kr) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentry_all__bindgen_ty_1), + "::", + stringify!(kr) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kc) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_kentry_all__bindgen_ty_1), + "::", + stringify!(kc) + ) + ); +} +#[test] +fn bindgen_test_layout_pfr_kentry_all() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 200usize, + concat!("Size of: ", stringify!(pfr_kentry_all)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_kentry_all)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).u) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_kentry_all), "::", stringify!(u)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_ktableworkq { + pub slh_first: *mut pfr_ktable, +} +#[test] +fn bindgen_test_layout_pfr_ktableworkq() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfr_ktableworkq)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_ktableworkq)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).slh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktableworkq), + "::", + stringify!(slh_first) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_ktablehead { + pub rbh_root: *mut pfr_ktable, +} +#[test] +fn bindgen_test_layout_pfr_ktablehead() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfr_ktablehead)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_ktablehead)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktablehead), + "::", + stringify!(rbh_root) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_ktable { + pub pfrkt_ts: pfr_tstats, + pub pfrkt_tree: pfr_ktable__bindgen_ty_1, + pub pfrkt_workq: pfr_ktable__bindgen_ty_2, + pub pfrkt_ip4: *mut radix_node_head, + pub pfrkt_ip6: *mut radix_node_head, + pub pfrkt_shadow: *mut pfr_ktable, + pub pfrkt_root: *mut pfr_ktable, + pub pfrkt_rs: *mut pf_ruleset, + pub pfrkt_larg: ::std::os::raw::c_long, + pub pfrkt_nflags: ::std::os::raw::c_int, + pub pfrkt_refcntcost: u_int64_t, + pub pfrkt_gcdweight: u_int16_t, + pub pfrkt_maxweight: u_int16_t, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_ktable__bindgen_ty_1 { + pub rbe_left: *mut pfr_ktable, + pub rbe_right: *mut pfr_ktable, + pub rbe_parent: *mut pfr_ktable, + pub rbe_color: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfr_ktable__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pfr_ktable__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_ktable__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_left) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable__bindgen_ty_1), + "::", + stringify!(rbe_left) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_right) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable__bindgen_ty_1), + "::", + stringify!(rbe_right) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_parent) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable__bindgen_ty_1), + "::", + stringify!(rbe_parent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_color) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable__bindgen_ty_1), + "::", + stringify!(rbe_color) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfr_ktable__bindgen_ty_2 { + pub sle_next: *mut pfr_ktable, +} +#[test] +fn bindgen_test_layout_pfr_ktable__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfr_ktable__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_ktable__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sle_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable__bindgen_ty_2), + "::", + stringify!(sle_next) + ) + ); +} +#[test] +fn bindgen_test_layout_pfr_ktable() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1344usize, + concat!("Size of: ", stringify!(pfr_ktable)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfr_ktable)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_ts) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfr_ktable), "::", stringify!(pfrkt_ts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_tree) as usize - ptr as usize }, + 1232usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable), + "::", + stringify!(pfrkt_tree) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_workq) as usize - ptr as usize }, + 1264usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable), + "::", + stringify!(pfrkt_workq) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_ip4) as usize - ptr as usize }, + 1272usize, + concat!("Offset of field: ", stringify!(pfr_ktable), "::", stringify!(pfrkt_ip4)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_ip6) as usize - ptr as usize }, + 1280usize, + concat!("Offset of field: ", stringify!(pfr_ktable), "::", stringify!(pfrkt_ip6)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_shadow) as usize - ptr as usize }, + 1288usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable), + "::", + stringify!(pfrkt_shadow) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_root) as usize - ptr as usize }, + 1296usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable), + "::", + stringify!(pfrkt_root) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_rs) as usize - ptr as usize }, + 1304usize, + concat!("Offset of field: ", stringify!(pfr_ktable), "::", stringify!(pfrkt_rs)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_larg) as usize - ptr as usize }, + 1312usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable), + "::", + stringify!(pfrkt_larg) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_nflags) as usize - ptr as usize }, + 1320usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable), + "::", + stringify!(pfrkt_nflags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_refcntcost) as usize - ptr as usize }, + 1328usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable), + "::", + stringify!(pfrkt_refcntcost) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_gcdweight) as usize - ptr as usize }, + 1336usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable), + "::", + stringify!(pfrkt_gcdweight) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrkt_maxweight) as usize - ptr as usize }, + 1338usize, + concat!( + "Offset of field: ", + stringify!(pfr_ktable), + "::", + stringify!(pfrkt_maxweight) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_tree_ext_gwy { + pub rbh_root: *mut pf_state_key, +} +#[test] +fn bindgen_test_layout_pf_state_tree_ext_gwy() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_state_tree_ext_gwy)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_state_tree_ext_gwy)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_state_tree_ext_gwy), + "::", + stringify!(rbh_root) + ) + ); +} +extern "C" { + pub fn pf_state_tree_ext_gwy_RB_INSERT_COLOR(arg1: *mut pf_state_tree_ext_gwy, arg2: *mut pf_state_key); +} +extern "C" { + pub fn pf_state_tree_ext_gwy_RB_REMOVE_COLOR( + arg1: *mut pf_state_tree_ext_gwy, + arg2: *mut pf_state_key, + arg3: *mut pf_state_key, + ); +} +extern "C" { + pub fn pf_state_tree_ext_gwy_RB_REMOVE( + arg1: *mut pf_state_tree_ext_gwy, + arg2: *mut pf_state_key, + ) -> *mut pf_state_key; +} +extern "C" { + pub fn pf_state_tree_ext_gwy_RB_INSERT( + arg1: *mut pf_state_tree_ext_gwy, + arg2: *mut pf_state_key, + ) -> *mut pf_state_key; +} +extern "C" { + pub fn pf_state_tree_ext_gwy_RB_FIND( + arg1: *mut pf_state_tree_ext_gwy, + arg2: *mut pf_state_key, + ) -> *mut pf_state_key; +} +extern "C" { + pub fn pf_state_tree_ext_gwy_RB_NFIND( + arg1: *mut pf_state_tree_ext_gwy, + arg2: *mut pf_state_key, + ) -> *mut pf_state_key; +} +extern "C" { + pub fn pf_state_tree_ext_gwy_RB_NEXT(arg1: *mut pf_state_key) -> *mut pf_state_key; +} +extern "C" { + pub fn pf_state_tree_ext_gwy_RB_PREV(arg1: *mut pf_state_key) -> *mut pf_state_key; +} +extern "C" { + pub fn pf_state_tree_ext_gwy_RB_MINMAX( + arg1: *mut pf_state_tree_ext_gwy, + arg2: ::std::os::raw::c_int, + ) -> *mut pf_state_key; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_ifhead { + pub rbh_root: *mut pfi_kif, +} +#[test] +fn bindgen_test_layout_pfi_ifhead() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfi_ifhead)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_ifhead)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbh_root) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfi_ifhead), "::", stringify!(rbh_root)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_tree { + _unused: [u8; 0], +} +extern "C" { + pub static mut pf_statetbl: pf_state_tree; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_kif_cmp { + pub pfik_name: [::std::os::raw::c_char; 16usize], +} +#[test] +fn bindgen_test_layout_pfi_kif_cmp() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfi_kif_cmp)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfi_kif_cmp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif_cmp), + "::", + stringify!(pfik_name) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifnet { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifg_group { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_kif { + pub pfik_name: [::std::os::raw::c_char; 16usize], + pub pfik_tree: pfi_kif__bindgen_ty_1, + pub pfik_packets: [[[u_int64_t; 2usize]; 2usize]; 2usize], + pub pfik_bytes: [[[u_int64_t; 2usize]; 2usize]; 2usize], + pub pfik_tzero: time_t, + pub pfik_flags: ::std::os::raw::c_int, + pub pfik_flags_new: ::std::os::raw::c_int, + pub pfik_ah_cookie: *mut ::std::os::raw::c_void, + pub pfik_ifp: *mut ifnet, + pub pfik_group: *mut ifg_group, + pub pfik_states: ::std::os::raw::c_int, + pub pfik_rules: ::std::os::raw::c_int, + pub pfik_routes: ::std::os::raw::c_int, + pub pfik_srcnodes: ::std::os::raw::c_int, + pub pfik_flagrefs: ::std::os::raw::c_int, + pub pfik_dynaddrs: pfi_kif__bindgen_ty_2, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_kif__bindgen_ty_1 { + pub rbe_left: *mut pfi_kif, + pub rbe_right: *mut pfi_kif, + pub rbe_parent: *mut pfi_kif, + pub rbe_color: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfi_kif__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pfi_kif__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_kif__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_left) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_1), + "::", + stringify!(rbe_left) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_right) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_1), + "::", + stringify!(rbe_right) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_parent) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_1), + "::", + stringify!(rbe_parent) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rbe_color) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_1), + "::", + stringify!(rbe_color) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_kif__bindgen_ty_2 { + pub tqh_first: *mut pfi_dynaddr, + pub tqh_last: *mut *mut pfi_dynaddr, +} +#[test] +fn bindgen_test_layout_pfi_kif__bindgen_ty_2() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfi_kif__bindgen_ty_2)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_kif__bindgen_ty_2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_first) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_2), + "::", + stringify!(tqh_first) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqh_last) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif__bindgen_ty_2), + "::", + stringify!(tqh_last) + ) + ); +} +#[test] +fn bindgen_test_layout_pfi_kif() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 256usize, + concat!("Size of: ", stringify!(pfi_kif)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfi_kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_name) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_tree) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_tree)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_packets) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_packets)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_bytes) as usize - ptr as usize }, + 112usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_bytes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_tzero) as usize - ptr as usize }, + 176usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_tzero)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_flags) as usize - ptr as usize }, + 184usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_flags_new) as usize - ptr as usize }, + 188usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif), + "::", + stringify!(pfik_flags_new) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_ah_cookie) as usize - ptr as usize }, + 192usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif), + "::", + stringify!(pfik_ah_cookie) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_ifp) as usize - ptr as usize }, + 200usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_ifp)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_group) as usize - ptr as usize }, + 208usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_group)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_states) as usize - ptr as usize }, + 216usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_rules) as usize - ptr as usize }, + 220usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_rules)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_routes) as usize - ptr as usize }, + 224usize, + concat!("Offset of field: ", stringify!(pfi_kif), "::", stringify!(pfik_routes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_srcnodes) as usize - ptr as usize }, + 228usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif), + "::", + stringify!(pfik_srcnodes) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_flagrefs) as usize - ptr as usize }, + 232usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif), + "::", + stringify!(pfik_flagrefs) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfik_dynaddrs) as usize - ptr as usize }, + 240usize, + concat!( + "Offset of field: ", + stringify!(pfi_kif), + "::", + stringify!(pfik_dynaddrs) + ) + ); +} +pub const pfi_kif_refs_PFI_KIF_REF_NONE: pfi_kif_refs = 0; +pub const pfi_kif_refs_PFI_KIF_REF_STATE: pfi_kif_refs = 1; +pub const pfi_kif_refs_PFI_KIF_REF_RULE: pfi_kif_refs = 2; +pub const pfi_kif_refs_PFI_KIF_REF_ROUTE: pfi_kif_refs = 3; +pub const pfi_kif_refs_PFI_KIF_REF_SRCNODE: pfi_kif_refs = 4; +pub const pfi_kif_refs_PFI_KIF_REF_FLAG: pfi_kif_refs = 5; +pub type pfi_kif_refs = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_status { + pub counters: [u_int64_t; 17usize], + pub lcounters: [u_int64_t; 10usize], + pub fcounters: [u_int64_t; 3usize], + pub scounters: [u_int64_t; 3usize], + pub pcounters: [[[u_int64_t; 3usize]; 2usize]; 2usize], + pub bcounters: [[u_int64_t; 2usize]; 2usize], + pub stateid: u_int64_t, + pub syncookies_inflight: [u_int64_t; 2usize], + pub since: time_t, + pub running: u_int32_t, + pub states: u_int32_t, + pub states_halfopen: u_int32_t, + pub src_nodes: u_int32_t, + pub debug: u_int32_t, + pub hostid: u_int32_t, + pub reass: u_int32_t, + pub syncookies_active: u_int8_t, + pub syncookies_mode: u_int8_t, + pub pad: [u_int8_t; 2usize], + pub ifname: [::std::os::raw::c_char; 16usize], + pub pf_chksum: [u_int8_t; 16usize], +} +#[test] +fn bindgen_test_layout_pf_status() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 488usize, + concat!("Size of: ", stringify!(pf_status)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_status)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).counters) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(counters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lcounters) as usize - ptr as usize }, + 136usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(lcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fcounters) as usize - ptr as usize }, + 216usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(fcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).scounters) as usize - ptr as usize }, + 240usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(scounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pcounters) as usize - ptr as usize }, + 264usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(pcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).bcounters) as usize - ptr as usize }, + 360usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(bcounters)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).stateid) as usize - ptr as usize }, + 392usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(stateid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).syncookies_inflight) as usize - ptr as usize }, + 400usize, + concat!( + "Offset of field: ", + stringify!(pf_status), + "::", + stringify!(syncookies_inflight) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).since) as usize - ptr as usize }, + 416usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(since)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).running) as usize - ptr as usize }, + 424usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(running)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize }, + 428usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).states_halfopen) as usize - ptr as usize }, + 432usize, + concat!( + "Offset of field: ", + stringify!(pf_status), + "::", + stringify!(states_halfopen) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).src_nodes) as usize - ptr as usize }, + 436usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(src_nodes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).debug) as usize - ptr as usize }, + 440usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(debug)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hostid) as usize - ptr as usize }, + 444usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(hostid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reass) as usize - ptr as usize }, + 448usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(reass)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).syncookies_active) as usize - ptr as usize }, + 452usize, + concat!( + "Offset of field: ", + stringify!(pf_status), + "::", + stringify!(syncookies_active) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).syncookies_mode) as usize - ptr as usize }, + 453usize, + concat!( + "Offset of field: ", + stringify!(pf_status), + "::", + stringify!(syncookies_mode) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize }, + 454usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(pad)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 456usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pf_chksum) as usize - ptr as usize }, + 472usize, + concat!("Offset of field: ", stringify!(pf_status), "::", stringify!(pf_chksum)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_queue_bwspec { + pub absolute: u_int, + pub percent: u_int, +} +#[test] +fn bindgen_test_layout_pf_queue_bwspec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pf_queue_bwspec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_queue_bwspec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).absolute) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_queue_bwspec), + "::", + stringify!(absolute) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).percent) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pf_queue_bwspec), + "::", + stringify!(percent) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_queue_scspec { + pub m1: pf_queue_bwspec, + pub m2: pf_queue_bwspec, + pub d: u_int, +} +#[test] +fn bindgen_test_layout_pf_queue_scspec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 20usize, + concat!("Size of: ", stringify!(pf_queue_scspec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_queue_scspec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).m1) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_queue_scspec), "::", stringify!(m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).m2) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pf_queue_scspec), "::", stringify!(m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).d) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_queue_scspec), "::", stringify!(d)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_queue_fqspec { + pub flows: u_int, + pub quantum: u_int, + pub target: u_int, + pub interval: u_int, +} +#[test] +fn bindgen_test_layout_pf_queue_fqspec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_queue_fqspec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_queue_fqspec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flows) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_queue_fqspec), + "::", + stringify!(flows) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).quantum) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pf_queue_fqspec), + "::", + stringify!(quantum) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).target) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_queue_fqspec), + "::", + stringify!(target) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).interval) as usize - ptr as usize }, + 12usize, + concat!( + "Offset of field: ", + stringify!(pf_queue_fqspec), + "::", + stringify!(interval) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_queuespec { + pub entries: pf_queuespec__bindgen_ty_1, + pub qname: [::std::os::raw::c_char; 64usize], + pub parent: [::std::os::raw::c_char; 64usize], + pub ifname: [::std::os::raw::c_char; 16usize], + pub realtime: pf_queue_scspec, + pub linkshare: pf_queue_scspec, + pub upperlimit: pf_queue_scspec, + pub flowqueue: pf_queue_fqspec, + pub kif: *mut pfi_kif, + pub flags: u_int, + pub qlimit: u_int, + pub qid: u_int32_t, + pub parent_qid: u_int32_t, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_queuespec__bindgen_ty_1 { + pub tqe_next: *mut pf_queuespec, + pub tqe_prev: *mut *mut pf_queuespec, +} +#[test] +fn bindgen_test_layout_pf_queuespec__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_queuespec__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_queuespec__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_queuespec__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_queuespec__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_queuespec() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 264usize, + concat!("Size of: ", stringify!(pf_queuespec)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_queuespec)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_queuespec), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qname) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_queuespec), "::", stringify!(qname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_queuespec), "::", stringify!(parent)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifname) as usize - ptr as usize }, + 144usize, + concat!("Offset of field: ", stringify!(pf_queuespec), "::", stringify!(ifname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).realtime) as usize - ptr as usize }, + 160usize, + concat!( + "Offset of field: ", + stringify!(pf_queuespec), + "::", + stringify!(realtime) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).linkshare) as usize - ptr as usize }, + 180usize, + concat!( + "Offset of field: ", + stringify!(pf_queuespec), + "::", + stringify!(linkshare) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).upperlimit) as usize - ptr as usize }, + 200usize, + concat!( + "Offset of field: ", + stringify!(pf_queuespec), + "::", + stringify!(upperlimit) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flowqueue) as usize - ptr as usize }, + 220usize, + concat!( + "Offset of field: ", + stringify!(pf_queuespec), + "::", + stringify!(flowqueue) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).kif) as usize - ptr as usize }, + 240usize, + concat!("Offset of field: ", stringify!(pf_queuespec), "::", stringify!(kif)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 248usize, + concat!("Offset of field: ", stringify!(pf_queuespec), "::", stringify!(flags)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qlimit) as usize - ptr as usize }, + 252usize, + concat!("Offset of field: ", stringify!(pf_queuespec), "::", stringify!(qlimit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).qid) as usize - ptr as usize }, + 256usize, + concat!("Offset of field: ", stringify!(pf_queuespec), "::", stringify!(qid)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).parent_qid) as usize - ptr as usize }, + 260usize, + concat!( + "Offset of field: ", + stringify!(pf_queuespec), + "::", + stringify!(parent_qid) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct priq_opts { + pub flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_priq_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(priq_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(priq_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(priq_opts), "::", stringify!(flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct hfsc_opts { + pub rtsc_m1: u_int, + pub rtsc_d: u_int, + pub rtsc_m2: u_int, + pub lssc_m1: u_int, + pub lssc_d: u_int, + pub lssc_m2: u_int, + pub ulsc_m1: u_int, + pub ulsc_d: u_int, + pub ulsc_m2: u_int, + pub flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_hfsc_opts() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(hfsc_opts)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(hfsc_opts)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_m1) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(rtsc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_d) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(rtsc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rtsc_m2) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(rtsc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m1) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(lssc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_d) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(lssc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lssc_m2) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(lssc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_m1) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(ulsc_m1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_d) as usize - ptr as usize }, + 28usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(ulsc_d)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ulsc_m2) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(ulsc_m2)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, + 36usize, + concat!("Offset of field: ", stringify!(hfsc_opts), "::", stringify!(flags)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfq_ops { + pub pfq_alloc: ::std::option::Option *mut ::std::os::raw::c_void>, + pub pfq_addqueue: ::std::option::Option< + unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void, arg2: *mut pf_queuespec) -> ::std::os::raw::c_int, + >, + pub pfq_free: ::std::option::Option, + pub pfq_qstats: ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut pf_queuespec, + arg2: *mut ::std::os::raw::c_void, + arg3: *mut ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int, + >, + pub pfq_qlength: + ::std::option::Option ::std::os::raw::c_uint>, + pub pfq_enqueue: + ::std::option::Option *mut mbuf>, + pub pfq_deq_begin: ::std::option::Option< + unsafe extern "C" fn( + arg1: *mut ::std::os::raw::c_void, + arg2: *mut *mut ::std::os::raw::c_void, + arg3: *mut mbuf_list, + ) -> *mut mbuf, + >, + pub pfq_deq_commit: ::std::option::Option< + unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void, arg2: *mut mbuf, arg3: *mut ::std::os::raw::c_void), + >, + pub pfq_purge: ::std::option::Option, +} +#[test] +fn bindgen_test_layout_pfq_ops() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 72usize, + concat!("Size of: ", stringify!(pfq_ops)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfq_ops)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfq_alloc) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfq_ops), "::", stringify!(pfq_alloc)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfq_addqueue) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfq_ops), "::", stringify!(pfq_addqueue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfq_free) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfq_ops), "::", stringify!(pfq_free)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfq_qstats) as usize - ptr as usize }, + 24usize, + concat!("Offset of field: ", stringify!(pfq_ops), "::", stringify!(pfq_qstats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfq_qlength) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pfq_ops), "::", stringify!(pfq_qlength)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfq_enqueue) as usize - ptr as usize }, + 40usize, + concat!("Offset of field: ", stringify!(pfq_ops), "::", stringify!(pfq_enqueue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfq_deq_begin) as usize - ptr as usize }, + 48usize, + concat!( + "Offset of field: ", + stringify!(pfq_ops), + "::", + stringify!(pfq_deq_begin) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfq_deq_commit) as usize - ptr as usize }, + 56usize, + concat!( + "Offset of field: ", + stringify!(pfq_ops), + "::", + stringify!(pfq_deq_commit) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfq_purge) as usize - ptr as usize }, + 64usize, + concat!("Offset of field: ", stringify!(pfq_ops), "::", stringify!(pfq_purge)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_tagname { + pub entries: pf_tagname__bindgen_ty_1, + pub name: [::std::os::raw::c_char; 64usize], + pub tag: u_int16_t, + pub ref_: ::std::os::raw::c_int, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_tagname__bindgen_ty_1 { + pub tqe_next: *mut pf_tagname, + pub tqe_prev: *mut *mut pf_tagname, +} +#[test] +fn bindgen_test_layout_pf_tagname__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pf_tagname__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_tagname__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_next) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pf_tagname__bindgen_ty_1), + "::", + stringify!(tqe_next) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tqe_prev) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pf_tagname__bindgen_ty_1), + "::", + stringify!(tqe_prev) + ) + ); +} +#[test] +fn bindgen_test_layout_pf_tagname() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 88usize, + concat!("Size of: ", stringify!(pf_tagname)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_tagname)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_tagname), "::", stringify!(entries)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_tagname), "::", stringify!(name)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).tag) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_tagname), "::", stringify!(tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ref_) as usize - ptr as usize }, + 84usize, + concat!("Offset of field: ", stringify!(pf_tagname), "::", stringify!(ref_)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pf_divert { + pub addr: pf_addr, + pub port: u_int16_t, + pub rdomain: u_int16_t, + pub type_: u_int8_t, +} +#[test] +fn bindgen_test_layout_pf_divert() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pf_divert)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pf_divert)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_divert), "::", stringify!(addr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pf_divert), "::", stringify!(port)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdomain) as usize - ptr as usize }, + 18usize, + concat!("Offset of field: ", stringify!(pf_divert), "::", stringify!(rdomain)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 20usize, + concat!("Offset of field: ", stringify!(pf_divert), "::", stringify!(type_)) + ); +} +pub const pf_divert_types_PF_DIVERT_NONE: pf_divert_types = 0; +pub const pf_divert_types_PF_DIVERT_TO: pf_divert_types = 1; +pub const pf_divert_types_PF_DIVERT_REPLY: pf_divert_types = 2; +pub const pf_divert_types_PF_DIVERT_PACKET: pf_divert_types = 3; +pub type pf_divert_types = ::std::os::raw::c_uint; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_pktdelay { + pub to: timeout, + pub m: *mut mbuf, + pub ifidx: u_int, +} +#[test] +fn bindgen_test_layout_pf_pktdelay() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 88usize, + concat!("Size of: ", stringify!(pf_pktdelay)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pf_pktdelay)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).to) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pf_pktdelay), "::", stringify!(to)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).m) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(pf_pktdelay), "::", stringify!(m)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ifidx) as usize - ptr as usize }, + 80usize, + concat!("Offset of field: ", stringify!(pf_pktdelay), "::", stringify!(ifidx)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_rule { + pub action: u_int32_t, + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub anchor: [::std::os::raw::c_char; 1024usize], + pub anchor_call: [::std::os::raw::c_char; 1024usize], + pub rule: pf_rule, +} +#[test] +fn bindgen_test_layout_pfioc_rule() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 3408usize, + concat!("Size of: ", stringify!(pfioc_rule)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_rule)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(action)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 12usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(anchor)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor_call) as usize - ptr as usize }, + 1036usize, + concat!( + "Offset of field: ", + stringify!(pfioc_rule), + "::", + stringify!(anchor_call) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rule) as usize - ptr as usize }, + 2064usize, + concat!("Offset of field: ", stringify!(pfioc_rule), "::", stringify!(rule)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_natlook { + pub saddr: pf_addr, + pub daddr: pf_addr, + pub rsaddr: pf_addr, + pub rdaddr: pf_addr, + pub rdomain: u_int16_t, + pub rrdomain: u_int16_t, + pub sport: u_int16_t, + pub dport: u_int16_t, + pub rsport: u_int16_t, + pub rdport: u_int16_t, + pub af: sa_family_t, + pub proto: u_int8_t, + pub direction: u_int8_t, +} +#[test] +fn bindgen_test_layout_pfioc_natlook() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 80usize, + concat!("Size of: ", stringify!(pfioc_natlook)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_natlook)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).saddr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(saddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).daddr) as usize - ptr as usize }, + 16usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(daddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rsaddr) as usize - ptr as usize }, + 32usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rsaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdaddr) as usize - ptr as usize }, + 48usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rdaddr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdomain) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(pfioc_natlook), + "::", + stringify!(rdomain) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rrdomain) as usize - ptr as usize }, + 66usize, + concat!( + "Offset of field: ", + stringify!(pfioc_natlook), + "::", + stringify!(rrdomain) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).sport) as usize - ptr as usize }, + 68usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(sport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).dport) as usize - ptr as usize }, + 70usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(dport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rsport) as usize - ptr as usize }, + 72usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rsport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).rdport) as usize - ptr as usize }, + 74usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(rdport)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).af) as usize - ptr as usize }, + 76usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(af)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).proto) as usize - ptr as usize }, + 77usize, + concat!("Offset of field: ", stringify!(pfioc_natlook), "::", stringify!(proto)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).direction) as usize - ptr as usize }, + 78usize, + concat!( + "Offset of field: ", + stringify!(pfioc_natlook), + "::", + stringify!(direction) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_state { + pub state: pfsync_state, +} +#[test] +fn bindgen_test_layout_pfioc_state() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 264usize, + concat!("Size of: ", stringify!(pfioc_state)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(pfioc_state)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_state), "::", stringify!(state)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_src_node_kill { + pub psnk_af: sa_family_t, + pub psnk_src: pf_rule_addr, + pub psnk_dst: pf_rule_addr, + pub psnk_killed: u_int, +} +#[test] +fn bindgen_test_layout_pfioc_src_node_kill() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(pfioc_src_node_kill)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_src_node_kill)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_af) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_af) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_src) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_src) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_dst) as usize - ptr as usize }, + 64usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_dst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psnk_killed) as usize - ptr as usize }, + 120usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_node_kill), + "::", + stringify!(psnk_killed) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_state_kill { + pub psk_pfcmp: pf_state_cmp, + pub psk_af: sa_family_t, + pub psk_proto: ::std::os::raw::c_int, + pub psk_src: pf_rule_addr, + pub psk_dst: pf_rule_addr, + pub psk_ifname: [::std::os::raw::c_char; 16usize], + pub psk_label: [::std::os::raw::c_char; 64usize], + pub psk_killed: u_int, + pub psk_rdomain: u_int16_t, +} +#[test] +fn bindgen_test_layout_pfioc_state_kill() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 224usize, + concat!("Size of: ", stringify!(pfioc_state_kill)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_state_kill)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_pfcmp) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_pfcmp) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_af) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_af) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_proto) as usize - ptr as usize }, + 20usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_proto) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_src) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_src) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_dst) as usize - ptr as usize }, + 80usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_dst) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_ifname) as usize - ptr as usize }, + 136usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_ifname) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_label) as usize - ptr as usize }, + 152usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_label) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_killed) as usize - ptr as usize }, + 216usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_killed) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psk_rdomain) as usize - ptr as usize }, + 220usize, + concat!( + "Offset of field: ", + stringify!(pfioc_state_kill), + "::", + stringify!(psk_rdomain) + ) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_states { + pub ps_len: usize, + pub ps_u: pfioc_states__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfioc_states__bindgen_ty_1 { + pub psu_buf: caddr_t, + pub psu_states: *mut pfsync_state, +} +#[test] +fn bindgen_test_layout_pfioc_states__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_states__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_states__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psu_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states__bindgen_ty_1), + "::", + stringify!(psu_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psu_states) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_states__bindgen_ty_1), + "::", + stringify!(psu_states) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_states() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_states)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_states)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_len) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_states), "::", stringify!(ps_len)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ps_u) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_states), "::", stringify!(ps_u)) + ); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct pfioc_src_nodes { + pub psn_len: usize, + pub psn_u: pfioc_src_nodes__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pfioc_src_nodes__bindgen_ty_1 { + pub psu_buf: caddr_t, + pub psu_src_nodes: *mut pf_src_node, +} +#[test] +fn bindgen_test_layout_pfioc_src_nodes__bindgen_ty_1() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_src_nodes__bindgen_ty_1)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_src_nodes__bindgen_ty_1)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psu_buf) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes__bindgen_ty_1), + "::", + stringify!(psu_buf) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psu_src_nodes) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes__bindgen_ty_1), + "::", + stringify!(psu_src_nodes) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_src_nodes() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_src_nodes)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_src_nodes)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psn_len) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes), + "::", + stringify!(psn_len) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).psn_u) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(pfioc_src_nodes), + "::", + stringify!(psn_u) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_tm { + pub timeout: ::std::os::raw::c_int, + pub seconds: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfioc_tm() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_tm)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_tm)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).timeout) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_tm), "::", stringify!(timeout)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).seconds) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_tm), "::", stringify!(seconds)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_limit { + pub index: ::std::os::raw::c_int, + pub limit: ::std::os::raw::c_uint, +} +#[test] +fn bindgen_test_layout_pfioc_limit() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_limit)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_limit)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).index) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_limit), "::", stringify!(index)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_limit), "::", stringify!(limit)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_ruleset { + pub nr: u_int32_t, + pub path: [::std::os::raw::c_char; 1024usize], + pub name: [::std::os::raw::c_char; 64usize], +} +#[test] +fn bindgen_test_layout_pfioc_ruleset() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1092usize, + concat!("Size of: ", stringify!(pfioc_ruleset)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_ruleset)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_ruleset), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).path) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_ruleset), "::", stringify!(path)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, + 1028usize, + concat!("Offset of field: ", stringify!(pfioc_ruleset), "::", stringify!(name)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_trans { + pub size: ::std::os::raw::c_int, + pub esize: ::std::os::raw::c_int, + pub array: *mut pfioc_trans_pfioc_trans_e, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_trans_pfioc_trans_e { + pub type_: ::std::os::raw::c_int, + pub anchor: [::std::os::raw::c_char; 1024usize], + pub ticket: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfioc_trans_pfioc_trans_e() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1032usize, + concat!("Size of: ", stringify!(pfioc_trans_pfioc_trans_e)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_trans_pfioc_trans_e)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_trans_pfioc_trans_e), + "::", + stringify!(type_) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).anchor) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pfioc_trans_pfioc_trans_e), + "::", + stringify!(anchor) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 1028usize, + concat!( + "Offset of field: ", + stringify!(pfioc_trans_pfioc_trans_e), + "::", + stringify!(ticket) + ) + ); +} +#[test] +fn bindgen_test_layout_pfioc_trans() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(pfioc_trans)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_trans)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).size) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_trans), "::", stringify!(size)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).esize) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_trans), "::", stringify!(esize)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).array) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_trans), "::", stringify!(array)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_queue { + pub ticket: u_int32_t, + pub nr: u_int, + pub queue: pf_queuespec, +} +#[test] +fn bindgen_test_layout_pfioc_queue() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 272usize, + concat!("Size of: ", stringify!(pfioc_queue)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_queue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_queue), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_queue), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).queue) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_queue), "::", stringify!(queue)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_qstats { + pub ticket: u_int32_t, + pub nr: u_int32_t, + pub queue: pf_queuespec, + pub buf: *mut ::std::os::raw::c_void, + pub nbytes: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfioc_qstats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 288usize, + concat!("Size of: ", stringify!(pfioc_qstats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_qstats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).ticket) as usize - ptr as usize }, + 0usize, + concat!("Offset of field: ", stringify!(pfioc_qstats), "::", stringify!(ticket)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize }, + 4usize, + concat!("Offset of field: ", stringify!(pfioc_qstats), "::", stringify!(nr)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).queue) as usize - ptr as usize }, + 8usize, + concat!("Offset of field: ", stringify!(pfioc_qstats), "::", stringify!(queue)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).buf) as usize - ptr as usize }, + 272usize, + concat!("Offset of field: ", stringify!(pfioc_qstats), "::", stringify!(buf)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).nbytes) as usize - ptr as usize }, + 280usize, + concat!("Offset of field: ", stringify!(pfioc_qstats), "::", stringify!(nbytes)) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_table { + pub pfrio_table: pfr_table, + pub pfrio_buffer: *mut ::std::os::raw::c_void, + pub pfrio_esize: ::std::os::raw::c_int, + pub pfrio_size: ::std::os::raw::c_int, + pub pfrio_size2: ::std::os::raw::c_int, + pub pfrio_nadd: ::std::os::raw::c_int, + pub pfrio_ndel: ::std::os::raw::c_int, + pub pfrio_nchange: ::std::os::raw::c_int, + pub pfrio_flags: ::std::os::raw::c_int, + pub pfrio_ticket: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfioc_table() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 1104usize, + concat!("Size of: ", stringify!(pfioc_table)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_table)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_table) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_table) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_buffer) as usize - ptr as usize }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_buffer) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_esize) as usize - ptr as usize }, + 1072usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_esize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_size) as usize - ptr as usize }, + 1076usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_size2) as usize - ptr as usize }, + 1080usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_size2) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_nadd) as usize - ptr as usize }, + 1084usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_nadd) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_ndel) as usize - ptr as usize }, + 1088usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_ndel) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_nchange) as usize - ptr as usize }, + 1092usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_nchange) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_flags) as usize - ptr as usize }, + 1096usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_flags) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfrio_ticket) as usize - ptr as usize }, + 1100usize, + concat!( + "Offset of field: ", + stringify!(pfioc_table), + "::", + stringify!(pfrio_ticket) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_iface { + pub pfiio_name: [::std::os::raw::c_char; 16usize], + pub pfiio_buffer: *mut ::std::os::raw::c_void, + pub pfiio_esize: ::std::os::raw::c_int, + pub pfiio_size: ::std::os::raw::c_int, + pub pfiio_nzero: ::std::os::raw::c_int, + pub pfiio_flags: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pfioc_iface() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pfioc_iface)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pfioc_iface)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_name) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_name) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_buffer) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_buffer) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_esize) as usize - ptr as usize }, + 24usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_esize) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_size) as usize - ptr as usize }, + 28usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_size) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_nzero) as usize - ptr as usize }, + 32usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_nzero) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).pfiio_flags) as usize - ptr as usize }, + 36usize, + concat!( + "Offset of field: ", + stringify!(pfioc_iface), + "::", + stringify!(pfiio_flags) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfioc_synflwats { + pub hiwat: u_int32_t, + pub lowat: u_int32_t, +} +#[test] +fn bindgen_test_layout_pfioc_synflwats() { + const UNINIT: ::std::mem::MaybeUninit = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pfioc_synflwats)) + ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pfioc_synflwats)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).hiwat) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pfioc_synflwats), + "::", + stringify!(hiwat) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).lowat) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(pfioc_synflwats), + "::", + stringify!(lowat) + ) + ); +} +extern "C" { + pub static mut pf_anchors: pf_anchor_global; +} +extern "C" { + pub static mut pf_main_anchor: pf_anchor; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct tcphdr { + _unused: [u8; 0], +} +extern "C" { + pub fn pf_init_ruleset(arg1: *mut pf_ruleset); +} +extern "C" { + pub fn pf_anchor_setup( + arg1: *mut pf_rule, + arg2: *const pf_ruleset, + arg3: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_anchor_copyout( + arg1: *const pf_ruleset, + arg2: *const pf_rule, + arg3: *mut pfioc_rule, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_remove_anchor(arg1: *mut pf_rule); +} +extern "C" { + pub fn pf_remove_if_empty_ruleset(arg1: *mut pf_ruleset); +} +extern "C" { + pub fn pf_find_anchor(arg1: *const ::std::os::raw::c_char) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_find_ruleset(arg1: *const ::std::os::raw::c_char) -> *mut pf_ruleset; +} +extern "C" { + pub fn pf_get_leaf_ruleset( + arg1: *mut ::std::os::raw::c_char, + arg2: *mut *mut ::std::os::raw::c_char, + ) -> *mut pf_ruleset; +} +extern "C" { + pub fn pf_create_anchor(arg1: *mut pf_anchor, arg2: *const ::std::os::raw::c_char) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_find_or_create_ruleset(arg1: *const ::std::os::raw::c_char) -> *mut pf_ruleset; +} +extern "C" { + pub fn pf_rs_initialize(); +} +extern "C" { + pub fn pf_anchor_rele(arg1: *mut pf_anchor); +} +extern "C" { + pub fn pf_anchor_take(arg1: *mut pf_anchor) -> *mut pf_anchor; +} +extern "C" { + pub fn pf_osfp_add(arg1: *mut pf_osfp_ioctl) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_osfp_fingerprint_hdr( + arg1: *const ip, + arg2: *const ip6_hdr, + arg3: *const tcphdr, + ) -> *mut pf_os_fingerprint_pf_osfp_enlist; +} +extern "C" { + pub fn pf_osfp_flush(); +} +extern "C" { + pub fn pf_osfp_get(arg1: *mut pf_osfp_ioctl) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_osfp_initialize(); +} +extern "C" { + pub fn pf_osfp_match(arg1: *mut pf_os_fingerprint_pf_osfp_enlist, arg2: pf_osfp_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn pf_osfp_validate() -> *mut pf_os_fingerprint; +} +pub type __builtin_va_list = [__va_list_tag; 1usize]; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __va_list_tag { + pub gp_offset: ::std::os::raw::c_uint, + pub fp_offset: ::std::os::raw::c_uint, + pub overflow_arg_area: *mut ::std::os::raw::c_void, + pub reg_save_area: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout___va_list_tag() { + const UNINIT: ::std::mem::MaybeUninit<__va_list_tag> = ::std::mem::MaybeUninit::uninit(); + let ptr = UNINIT.as_ptr(); + assert_eq!( + ::std::mem::size_of::<__va_list_tag>(), + 24usize, + concat!("Size of: ", stringify!(__va_list_tag)) + ); + assert_eq!( + ::std::mem::align_of::<__va_list_tag>(), + 8usize, + concat!("Alignment of ", stringify!(__va_list_tag)) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).gp_offset) as usize - ptr as usize }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(gp_offset) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).fp_offset) as usize - ptr as usize }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(fp_offset) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).overflow_arg_area) as usize - ptr as usize }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(overflow_arg_area) + ) + ); + assert_eq!( + unsafe { ::std::ptr::addr_of!((*ptr).reg_save_area) as usize - ptr as usize }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__va_list_tag), + "::", + stringify!(reg_save_area) + ) + ); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct witness { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct process { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct ifaddr { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct rtentry { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pfi_dynaddr { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct pf_state_key { + pub _address: u8, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct mbuf { + _unused: [u8; 0], +} diff --git a/tproxy_tokio/src/tcp/linux/bind.rs b/tproxy_tokio/src/tcp/linux/bind.rs index 29a317c..76744d5 100755 --- a/tproxy_tokio/src/tcp/linux/bind.rs +++ b/tproxy_tokio/src/tcp/linux/bind.rs @@ -1,5 +1,5 @@ use std::{ - io::{self, Error, ErrorKind}, + io::{self, Error}, mem, net::SocketAddr, os::fd::AsRawFd, @@ -26,18 +26,13 @@ pub fn create_tproxy_listener(addr: SocketAddr) -> io::Result { Ok(listener) } -pub fn set_ip_transparent(level: libc::c_int, socket: &TcpSocket) -> io::Result<()> { +fn set_ip_transparent(level: libc::c_int, socket: &TcpSocket) -> io::Result<()> { let fd = socket.as_raw_fd(); let opt = match level { libc::IPPROTO_IP => libc::IP_TRANSPARENT, libc::IPPROTO_IPV6 => libc::IPV6_TRANSPARENT, - _ => { - return Err(Error::new( - ErrorKind::InvalidInput, - "level can only be IPPROTO_IP and IPPROTO_IPV6", - )) - } + _ => unreachable!("level can only be IPPROTO_IP and IPPROTO_IPV6"), }; let enable: libc::c_int = 1; diff --git a/tproxy_tokio/src/tcp/linux/destination.rs b/tproxy_tokio/src/tcp/linux/destination.rs index 45c745d..4b661bc 100755 --- a/tproxy_tokio/src/tcp/linux/destination.rs +++ b/tproxy_tokio/src/tcp/linux/destination.rs @@ -11,7 +11,7 @@ pub fn get_original_destination_addr(s: &TcpStream) -> io::Result { unsafe { let (_, target_addr) = SockAddr::try_init(|target_addr, target_addr_len| { - // No suffcient method to know whether the destination IPv4 or IPv6. + // No sufficient method to know whether the destination IPv4 or IPv6. let ret = libc::getsockopt( fd, diff --git a/tproxy_tokio/src/tcp/linux/mod.rs b/tproxy_tokio/src/tcp/linux/mod.rs index 06a3269..51ea01a 100755 --- a/tproxy_tokio/src/tcp/linux/mod.rs +++ b/tproxy_tokio/src/tcp/linux/mod.rs @@ -13,7 +13,7 @@ use async_trait::async_trait; #[async_trait] impl TcpListenerRedirExt for TcpListener { - async fn bind_redir(ty: RedirType, addr: SocketAddr) -> Result { + async fn bind_redir(ty: RedirType, addr: SocketAddr) -> io::Result { match ty { RedirType::Redirect => { // REDIRECT rule doesn't need to set IP_TRANSPARENT @@ -41,10 +41,7 @@ impl TcpStreamRedirExt for TcpStream { // For TPROXY, uses getsockname() to retrieve original destination address self.local_addr() } - _ => Err(Error::new( - ErrorKind::InvalidInput, - "not supported tcp transparent proxy type", - )), + _ => unreachable!("not supported tcp transparent proxy type"), } } } diff --git a/tproxy_tokio/src/tcp/mod.rs b/tproxy_tokio/src/tcp/mod.rs index 6b2ad37..e2d339c 100755 --- a/tproxy_tokio/src/tcp/mod.rs +++ b/tproxy_tokio/src/tcp/mod.rs @@ -23,15 +23,19 @@ use tokio::net::TcpListener; use async_trait::async_trait; use cfg_if::cfg_if; -/// Extension function for `TcpListener` for setting extra options before `bind()` +/// Extension function for `TcpListener` for setting extra options before `bind()` #[async_trait] pub trait TcpListenerRedirExt { - /// Create a TcpListener for transparent proxy + // Create a TcpListener for transparent proxy + // + // Implementation is platform dependent async fn bind_redir(ty: RedirType, addr: SocketAddr) -> io::Result; } -/// Extension function for `TcpStream` for reading original destination address +/// Extension function for `TcpStream` for reading original destination address pub trait TcpStreamRedirExt { - /// Read destination address for TcpStream + // Read destination address for TcpStream + // + // Implementation is platform dependent fn destination_addr(&self, ty: RedirType) -> io::Result; } diff --git a/tproxy_tokio/src/tcp/other.rs b/tproxy_tokio/src/tcp/other.rs index 341ef46..d24a779 100755 --- a/tproxy_tokio/src/tcp/other.rs +++ b/tproxy_tokio/src/tcp/other.rs @@ -13,7 +13,7 @@ impl TcpListenerRedirExt for TcpListener { async fn bind_redir(_ty: RedirType, _addr: SocketAddr) -> io::Result { let err = Error::new( ErrorKind::InvalidInput, - "not supported tcp transparent proxy on this platform", + "not supported tcp transparent proxy on Windows", ); Err(err) } @@ -21,6 +21,6 @@ impl TcpListenerRedirExt for TcpListener { impl TcpStreamRedirExt for TcpStream { fn destination_addr(&self, _ty: RedirType) -> io::Result { - unreachable!("not supported tcp transparent on this platform") + unreachable!("not supported tcp transparent on Windows") } }