Expand description
Unix API crate
NOTE: The crate documentation is in the docs
module.
Modules§
- Re-export of the libc crate with missing items added
- Module containing the crate documentation
Macros§
- Forwards its arguments to
format!
and wraps the result in aUstring
fn(<integer type>) -> Result<integer type>
fn(<string literal>) -> &'static Ustr
Structs§
- Transparent wrapper that asserts that a type is
Packed
- Transparent wrapper that asserts that a type is
Pod
- Thin wrapper for a
[u8]
- Wrapper for
*mut libc::DIR
- Wrapper for
*const libc::dirent
c_int
newtype which wrapsERRNO
values- A borrowed file descriptor
- A wrapper for a partially initialized
iovec
- An iterator over the initialized components of an
iovec
- Rusty version of an immutable
c::msghdr
- Rusty version of a mutable
c::msghdr
- An owned file descriptor
- Thin wrapper for a
[u8]
that has a trailing nul byte - Wrapper for a
*const *const libc::c_char
with a terminating null pointer - Thin wrapper for a
Vec<u8>
that has a trailing nul byte - Wrapper for
libc::utsname
Constants§
Traits§
- Used for cheap conversion from into
&Ustr
- Trait for objects which can be turned into bytes
- Trait for objects which can be turned into
Cow<'a, Ustr>
- A possibly uninitialized
iovec
- A possibly uninitialized
iovec
(mutable) - Extension for
MaybeUninit
- Marker trait for types without padding
- Marker trait for Pod types
- Marker trait for socket address types
Read
extensions
Functions§
- Returns the object representation of
t
- Returns the mutable object representation of
t
- Casts the argument to
MaybeUninit
of the same type - Returns the object representation of
t
- Returns the mutable object representation of
t
- Returns the mutable object representation of
t
- Casts the argument to
MaybeUninit
of the same type - Asserts that
T
isPacked
- Asserts that
T
isPod
- Reads a cmsg from a buffer
- Returns the number of bytes needed to store a cmsg with data-length
data_len
- Writes a cmsg to a buffer
- Returns an empty sig set
- Gets a pointer to the current thread’s errno
fcntl(2)
with cmd =F_DUPFD
fcntl(2)
with cmd =F_DUPFD_CLOEXEC
fcntl(2)
with cmd =F_GETFD
fcntl(2)
with cmd =F_GETFL
fcntl(2)
with cmd =F_GETLK
fcntl(2)
with cmd =F_SETFD
fcntl(2)
with cmd =F_SETFL
fcntl(2)
with cmd =F_SETLK
fcntl(2)
with cmd =F_SETLKW
- fork⚠
- Gets the current thread’s errno
- Returns
Option::<&mut [u8]>::None
- Returns
Option::<&[u8]>::None
- Converts
u
into an iterator ofT
- Converts
u
toT
- Converts an initial port of
u
toT
- Writes
u
tot
- Returns an instance of
T
whose object representation is0
in all non-padding bytes - Shortcut for
read_link_to_ustring
with a newUstring
- Sets the current thread’s errno
- Returns
Option::<&mut c::sockaddr>::None
- Returns
Option::<&c::sockaddr>::None