Closed
Description
miow
assumes that the memory layout of std::net::SocketAddrV{4,6}
matches libc::sockaddr
, but this can't be assumed. std
makes no such promise to the outside world.
The offending code is here:
Lines 459 to 470 in c863739
Some other crates made the same assumptions, and they are being fixed in tokio-rs/mio#1388, rust-lang/socket2#120 and deprecrated/net2-rs#106.
Until this is fixed and published it kind of blocks moving these fundamental network types into core
and also stops them from having const fn
constructors. See this PR on std
for reference: rust-lang/rust#78802.
Metadata
Metadata
Assignees
Labels
No labels