Skip to content

Commit

Permalink
fix: the build with feature 'socket' on macOS (#2514)
Browse files Browse the repository at this point in the history
  • Loading branch information
SteveLauC authored Sep 24, 2024
1 parent 9c0bdac commit 14fb973
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/sys/socket/sockopt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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<T: AsMut<[u8]>> {
len: socklen_t,
val: MaybeUninit<T>,
}

#[cfg(apple_targets)]
#[cfg(feature = "net")]
impl<T: AsMut<[u8]>> Get<CString> for GetCString<T> {
fn uninit() -> Self {
GetCString {
Expand Down

0 comments on commit 14fb973

Please sign in to comment.