Age | Commit message (Collapse) | Author |
|
|
|
1522: mman mod adding MAP_ALIGNED_SUPER flag for freebsd. r=asomers a=devnexen
Co-authored-by: David Carlier <devnexen@gmail.com>
|
|
And this time, start running Clippy in CI
|
|
|
|
1496: Rework UnixAddr to fix soundness issues r=asomers a=coolreader18
Fixes #1494
I went with making `sun_path` always nul-terminated since that just seems to make things easier, since (at least according to linux man pages) `sockaddr_un`s returned by the kernel will always be nul-terminated.
Co-authored-by: Noa <33094578+coolreader18@users.noreply.github.com>
|
|
|
|
1524: Add docs for most sockopts r=asomers a=asomers
Co-authored-by: Alan Somers <asomers@gmail.com>
|
|
|
|
|
|
This macro is not exported outside of the crate, so there's no danger.
|
|
1520: mman module netbsd additions. r=asomers a=devnexen
1523: mman: add MAP_STACK to openbsd which is needed … r=asomers a=devnexen
…to created stack mappings
Co-authored-by: David Carlier <devnexen@gmail.com>
|
|
|
|
|
|
1509: Allow Android to use timerfd r=asomers a=rtzoeller
This is a continuation of #1336 which also enables the timerfd tests.
```
running 3 tests
test sys::test_timerfd::test_timerfd_unset ... ok
test sys::test_timerfd::test_timerfd_oneshot ... ok
test sys::test_timerfd::test_timerfd_interval ... ok
```
1515: Add IP_TTL/IPV6_UNICAST_HOPS SockOpts r=asomers a=cemeyer
Test: `cargo test --test test test_ttl_opts`
Co-authored-by: Ryan Zoeller <rtzoeller@rtzoeller.com>
Co-authored-by: Conrad Meyer <cem@FreeBSD.org>
|
|
Test: `cargo test --test test test_ttl_opts`
|
|
|
|
Setting these options enables receiving errors, such as ICMP errors from
the network, via `recvmsg()` with `MSG_ERRQUEUE`.
Adds new `Ipv{4,6}RecvErr` variants to `ControlMessageOwned`. These
control messages are produced when `Ipv4RecvErr` or `Ipv6RecvErr`
options are enabled on a raw or datagram socket.
New tests for the functionality can be run with `cargo test --test test
test_recverr`.
This commit builds on an earlier draft of the functionality authored by
Matthew McPherrin <git@mcpherrin.ca>.
|
|
|
|
|
|
Build, but don't test, for these operating systems. Thanks to
@rtzoeller for the tip.
Also, fix the OpenBSD build.
|
|
|
|
|
|
Because nothing uses it on those OSes.
|
|
Also, test rustdoc in CI, and demote missing_docs from a deny to a
warning (but still deny it in CI).
|
|
Co-authored-by: zachoverflow <zach@zachjohnson.net>
|
|
|
|
Switch from allow(missing_docs) to deny(missing_docs), which should
gradually help us moving forward. Also, add a few missing docs, such as
for sched and aio.
|
|
1503: Add TcpRepair to sockopt r=asomers a=tazz4843
This PR adds the `TCP_REPAIR` flag to `nix::sys::socket::sockopt` under the name `TcpRepair`.
Co-authored-by: 0/0 <zero@imaskeleton.me>
|
|
|
|
|
|
1447: Expose SockAddr::from_raw_sockaddr r=asomers a=coolreader18
I also noticed the `SockAddr/InetAddr::to_str` functions were entirely redundant - `ToString` exists for that, & has a blanket impl on `T: Display`.
Co-authored-by: Noah <33094578+coolreader18@users.noreply.github.com>
|
|
1495: Deprecate SockAddr/InetAddr::to_str r=asomers a=coolreader18
Co-authored-by: Noah <33094578+coolreader18@users.noreply.github.com>
|
|
|
|
|
|
|
|
1486: Relax assertions in sockaddr_storage_to_addr to match the documentation. r=asomers a=khuey
Fixes #1479
1490: add libc::IP6T_SO_ORIGINAL_DST to socket opt r=asomers a=bearice
the original PR #1410 was stalled for a while
let's make it happen.
this should closes #1410 and #938
1493: Fix crates.io badge r=asomers a=atouchet
Co-authored-by: Kyle Huey <khuey@kylehuey.com>
Co-authored-by: Icemic <bingfeng.web@gmail.com>
Co-authored-by: Bearice Ren <bearice@icybear.net>
Co-authored-by: Alex Touchet <alextouchet@outlook.com>
|
|
Fixes #1479
|
|
There was a better case for using it before mem::uninitialized was
available, but not great. Even before then, mem::zeroed could've been
used instead.
Issue #373
|
|
mem::size_of has been a const fn since Rust 1.24.0. Use it.
|
|
Constify more functions, since we're raising the MSRV from 1.41.0 to
1.46.0.
Fixes #1477
|
|
|
|
1482: Add support for LOCAL_PEER_CRED r=asomers a=asomers
On FreeBSD and its derivatives, this socket option gets the credentials
of the connected peer.
Co-authored-by: Alan Somers <asomers@gmail.com>
|
|
1484: Optionally implement TryFrom in libc_enum! r=asomers a=asomers
This saves code in several separate places that need to do this
separately. At the same time, remove a few uses of mem::transmute that
were implementing TryFrom or similar functionality.
Issue #373
Co-authored-by: Alan Somers <asomers@gmail.com>
|
|
On FreeBSD and its derivatives, this socket option gets the credentials
of the connected peer.
|
|
This saves code in several separate places that need to do this
separately. At the same time, remove a few uses of mem::transmute that
were implementing TryFrom or similar functionality.
Issue #373
|
|
Issue #373
|
|
|
|
|
|
This work is a continutation on previou contribution by @kpcyrd and @j1ah0ng.
|
|
1473: sys/stat: add a safe wrapper for mknodat(2) r=asomers a=lucab
This introduces a new `mknodat` helper.
Ref: https://pubs.opengroup.org/onlinepubs/9699919799/functions/mknod.html
1474: Mark most C-derived enums as non_exhaustive r=asomers a=asomers
Since libc may add new variants at any time, Nix's consumers should not
use exhaustive match patterns.
Fixes #1182
1476: Constify many functions r=asomers a=asomers
Constify most functions that can be constified. The exceptions are
mostly accessors for structs that have no const constructor.
Co-authored-by: Luca BRUNO <luca.bruno@coreos.com>
Co-authored-by: Alan Somers <asomers@gmail.com>
|