diff --git a/Cargo.toml b/Cargo.toml index 18331f61..d0566282 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -51,7 +51,7 @@ targets = [ features = ["all"] [target."cfg(unix)".dependencies] -libc = "0.2.150" +libc = "0.2.171" [target.'cfg(windows)'.dependencies.windows-sys] version = "0.52" diff --git a/src/sys/unix.rs b/src/sys/unix.rs index c187d517..37d0c3a6 100644 --- a/src/sys/unix.rs +++ b/src/sys/unix.rs @@ -22,6 +22,8 @@ use std::net::{Ipv4Addr, Ipv6Addr}; target_os = "macos", target_os = "tvos", target_os = "watchos", + target_os = "illumos", + target_os = "solaris", ) ))] use std::num::NonZeroU32; @@ -1834,6 +1836,8 @@ impl crate::Socket { target_os = "macos", target_os = "tvos", target_os = "watchos", + target_os = "illumos", + target_os = "solaris", ) ))] pub fn bind_device_by_index_v4(&self, interface: Option) -> io::Result<()> { @@ -1859,6 +1863,8 @@ impl crate::Socket { target_os = "macos", target_os = "tvos", target_os = "watchos", + target_os = "illumos", + target_os = "solaris", ) ))] pub fn bind_device_by_index_v6(&self, interface: Option) -> io::Result<()> { @@ -1879,6 +1885,8 @@ impl crate::Socket { target_os = "macos", target_os = "tvos", target_os = "watchos", + target_os = "illumos", + target_os = "solaris", ) ))] pub fn device_index_v4(&self) -> io::Result> { @@ -1900,6 +1908,8 @@ impl crate::Socket { target_os = "macos", target_os = "tvos", target_os = "watchos", + target_os = "illumos", + target_os = "solaris", ) ))] pub fn device_index_v6(&self) -> io::Result> { diff --git a/tests/socket.rs b/tests/socket.rs index 3776a4b4..a2dca668 100644 --- a/tests/socket.rs +++ b/tests/socket.rs @@ -990,6 +990,8 @@ fn device() { target_os = "macos", target_os = "tvos", target_os = "watchos", + target_os = "solaris", + target_os = "illumos", ) ))] #[test] @@ -1036,6 +1038,8 @@ fn device() { target_os = "macos", target_os = "tvos", target_os = "watchos", + target_os = "solaris", + target_os = "illumos", ) ))] #[test]