mirror of
https://github.com/rust-lang/rust.git
synced 2025-01-25 14:13:38 +00:00
Add fake definitions for Windows
This commit is contained in:
parent
d0069a0cc5
commit
a81764731c
@ -11,6 +11,16 @@ use crate::sys::net::Socket;
|
||||
|
||||
#[cfg(any(target_os = "android", target_os = "linux",))]
|
||||
use libc::{gid_t, pid_t, uid_t};
|
||||
// FIXME(#43348): Make libc adapt #[doc(cfg(...))] so we don't need these fake definitions here?
|
||||
#[cfg(not(unix))]
|
||||
#[allow(non_camel_case_types)]
|
||||
mod libc {
|
||||
pub struct ucred;
|
||||
pub struct cmsghdr;
|
||||
pub type pid_t = i32;
|
||||
pub type gid_t = u32;
|
||||
pub type uid_t = u32;
|
||||
}
|
||||
|
||||
pub(super) fn recv_vectored_with_ancillary_from(
|
||||
socket: &Socket,
|
||||
|
Loading…
Reference in New Issue
Block a user