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
- Wrapper for
libc::inotify_event
- Rusty version of an immutable
c::msghdr
- Rusty version of a mutable
c::msghdr
- NlmsgWriterDeprecatedA writer for netlink messages
- 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
- NlmsgHeaderDeprecatedThe general shape of a header of a netlink message
- NlmsgHeaderExtDeprecatedExtension trait for netlink message headers
- 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
- Reads from an eventfd file descriptor
- Writes to an eventfd file descriptor
fcntl(2)
with cmd =F_ADD_SEALS
fcntl(2)
with cmd =F_DUPFD
fcntl(2)
with cmd =F_DUPFD_CLOEXEC
fcntl(2)
with cmd =F_GET_SEALS
fcntl(2)
with cmd =F_GETFD
fcntl(2)
with cmd =F_GETFL
fcntl(2)
with cmd =F_GETLK
fcntl(2)
with cmd =F_GETPIPE_SZ
fcntl(2)
with cmd =F_OFD_GETLK
fcntl(2)
with cmd =F_OFD_SETLK
fcntl(2)
with cmd =F_OFD_SETLKW
fcntl(2)
with cmd =F_SETFD
fcntl(2)
with cmd =F_SETFL
fcntl(2)
with cmd =F_SETLK
fcntl(2)
with cmd =F_SETLKW
fcntl(2)
with cmd =F_SETPIPE_SZ
- fork⚠
fsconfig(2)
with cmd =FSCONFIG_CMD_CREATE
fsconfig(2)
with cmd =FSCONFIG_CMD_RECONFIGURE
fsconfig(2)
with cmd =FSCONFIG_SET_BINARY
fsconfig(2)
with cmd =FSCONFIG_SET_FD
fsconfig(2)
with cmd =FSCONFIG_SET_FLAG
fsconfig(2)
with cmd =FSCONFIG_SET_PATH
fsconfig(2)
with cmd =FSCONFIG_SET_PATH_EMPTY
fsconfig(2)
with cmd =FSCONFIG_SET_STRING
- Gets the current thread’s errno
- Reads from an inotify file descriptor and returns an iterator over the results
- Returns
Option::<&mut [u8]>::None
- Returns
Option::<&[u8]>::None
- nlmsg_alignDeprecatedIncreases the size to the next multiple of 4
- nlmsg_readDeprecatedReads an object from an netlink message buffer
- 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
signalfd(2)
with fd !=-1
signalfd(2)
with fd =-1
- Reads from a signalfd file descriptor and returns the elements read
- Returns
Option::<&mut c::sockaddr>::None
- Returns
Option::<&c::sockaddr>::None