mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-16 13:05:18 +03:00
libc: Fix definition of sockaddr_storage on 32-bit linux
The alignment field is actually a "pointer sized" type instead of always i64, requiring that the size of the padding field is also calculated slightly differently. Closes #23425
This commit is contained in:
+2
-2
@@ -269,8 +269,8 @@ pub mod bsd44 {
|
||||
#[repr(C)]
|
||||
#[derive(Copy)] pub struct sockaddr_storage {
|
||||
pub ss_family: sa_family_t,
|
||||
pub __ss_align: i64,
|
||||
pub __ss_pad2: [u8; 112],
|
||||
pub __ss_align: isize,
|
||||
pub __ss_pad2: [u8; 128 - 2 * (::core::isize::BYTES as usize)],
|
||||
}
|
||||
#[repr(C)]
|
||||
#[derive(Copy)] pub struct sockaddr_in {
|
||||
|
||||
Reference in New Issue
Block a user