From 14fb9734c23eb524d22b7d63c1889f0f9fa698b8 Mon Sep 17 00:00:00 2001 From: SteveLauC Date: Tue, 24 Sep 2024 09:13:27 +0800 Subject: [PATCH] fix: the build with feature 'socket' on macOS (#2514) --- src/sys/socket/sockopt.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/sys/socket/sockopt.rs b/src/sys/socket/sockopt.rs index d061f1f179..e2f9f10b08 100644 --- a/src/sys/socket/sockopt.rs +++ b/src/sys/socket/sockopt.rs @@ -1697,12 +1697,14 @@ impl<'a> Set<'a, OsString> for SetOsString<'a> { /// Getter for a `CString` value. #[cfg(apple_targets)] +#[cfg(feature = "net")] struct GetCString> { len: socklen_t, val: MaybeUninit, } #[cfg(apple_targets)] +#[cfg(feature = "net")] impl> Get for GetCString { fn uninit() -> Self { GetCString {