mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-17 05:25:37 +03:00
Mark relevant structs with repr(C)
This commit is contained in:
@@ -143,6 +143,7 @@ pub fn swap(out_context: &mut Context, in_context: &Context) {
|
||||
// stacks are disabled.
|
||||
|
||||
#[cfg(target_arch = "x86")]
|
||||
#[repr(C)]
|
||||
struct Registers {
|
||||
eax: u32, ebx: u32, ecx: u32, edx: u32,
|
||||
ebp: u32, esi: u32, edi: u32, esp: u32,
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
static FD_SETSIZE: uint = 64;
|
||||
pub static MSG_DONTWAIT: libc::c_int = 0;
|
||||
|
||||
#[repr(C)]
|
||||
pub struct WSADATA {
|
||||
pub wVersion: libc::WORD,
|
||||
pub wHighVersion: libc::WORD,
|
||||
@@ -32,6 +33,7 @@ pub struct WSADATA {
|
||||
|
||||
pub type LPWSADATA = *mut WSADATA;
|
||||
|
||||
#[repr(C)]
|
||||
pub struct fd_set {
|
||||
fd_count: libc::c_uint,
|
||||
fd_array: [libc::SOCKET, ..FD_SETSIZE],
|
||||
|
||||
Reference in New Issue
Block a user