Age | Commit message (Collapse) | Author |
|
624: Enable ptrace on all Linux platforms r=Susurrus
Nothing that nix currently binds is architecture-specific, and Android
supports ptrace just as much as non-Android Linux.
|
|
|
|
|
|
|
|
|
|
Nothing that nix currently binds is architecture-specific, and Android
supports ptrace just as much as non-Android Linux.
|
|
the previous definition were linux specific.
|
|
|
|
|
|
625: Use libc_bitflags! for BSD in fcntl.rs r=Susurrus
|
|
|
|
|
|
|
|
|
|
This is necessary because certain flags in libc have different types, generally
due to a mistake when adding the flags to the libc. See
https://github.com/rust-lang/libc/pull/511 for an example of such a
discrepency.
|
|
Newtypes for uid_t, gid_t and pid_t.
|
|
|
|
|
|
|
|
599: Support powerpc64 r=Susurrus
The test_ioctl values are computed using ioctl-test.c
|
|
622: Separate OpenBSD and FreeBSD in fcntl.rs r=asomers
Those two OSes cannot be together since the following FreeBSD flags aren't available on OpenBSD.
- `O_DIRECT`
- `O_EXEC`
- `O_TTY_INIT`
|
|
The test_ioctl values are computed using ioctl-test.c
|
|
|
|
|
|
|
|
The officially documented type, and the type in sched.h, for this
argument is pid_t.
|
|
Some ptrace functions return structures through the data argument. This commit adds utilities to return data through this mechanism and function specialisations for a few of these functions (getting event messages or the siginfo_t struct). Once the next version of libc is released these utilities will be expanded to include the fpregs and user_regs structs.
Ptrace requests that are now satisfied by a more specific public function will return an unsupported operation error. This has involved adding an UnsupportedOperation to the nix::Error enum and removed the mapping from Error to Errno and from Error to std::io::Error.
|
|
|
|
|
|
* SigAction::flags()
* SigAction::mask()
* SigAction::handler()
|
|
* grantpt
* ptsname/ptsname_r
* posix_openpt
* unlockpt
|
|
|
|
|
|
The existing AioCb constructors work for simple programs where
everything is stored on the stack. But in more complicated programs the
borrow checker can't prove that a buffer will outlive the AioCb that
references it. Fix this problem by introducting
AioCb::from_boxed_slice, which takes a reference-counted buffer.
Fixes #575
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The nix::sys::mman::mmap documentation says
> Calls to mmap are inherently unsafe, so they must be made in an unsafe
block.
however, the function was not actually marked unsafe.
* `munmap` should also be `unsafe` for obvious reasons.
* `madvise` should be `unsafe` because of the MADV_DONTNEED flag.
* `mlock` was already marked `unsafe`
* `munlock` and `msync` don't strictly need to be `unsafe` despite
taking pointers AFAICT, but are marked `unsafe` for consistency and in
case they add additional flags in the future.
|
|
revents is an output field so regardless of what value it is set to it
will be overwritten by many of the function calls that take a PollFd.
The only value that makes sense for the caller to pass in in
`EventFlags::empty()` so we just hardcode that instead of making the
caller do it.
|
|
This allows importing them directly from `nix::fcntl` which is more
ergonomic than needing to use them via `FcntlArg`.
|
|
|