summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2023-06-29Merge #2027 #2057bors[bot]
2027: Update to bitflags 2.2.1. r=asomers a=qwandor This is a new major version and requires some code changes. 2057: Haiku: `speed_t` is defined as `u8` for 32 and 64 bit systems r=asomers a=nielx This fixes the build on 32 bit Haiku systems. Co-authored-by: Andrew Walbran <qwandor@google.com> Co-authored-by: Niels Sascha Reedijk <niels.reedijk@gmail.com>
2023-06-29Merge #2051bors[bot]
2051: Update CHANGELOG for patch release 0.26.2 r=asomers a=asomers [skip ci] Co-authored-by: Alan Somers <asomers@gmail.com>
2023-06-29Merge #2061bors[bot]
2061: For invalid IP address conversions with future Rust versions r=asomers a=asomers Rust's standard library no longer guarantees that Ipv4Addr and Ipv6Addr are wrappers around the C types (though for now at least, they are identical on all platforms I'm aware of). So do the conversions explicitly instead of transmuting. Fixes #2053 Co-authored-by: Alan Somers <asomers@gmail.com>
2023-06-27For invalid IP address conversions with future Rust versionsAlan Somers
Rust's standard library no longer guarantees that Ipv4Addr and Ipv6Addr are wrappers around the C types (though for now at least, they are identical on all platforms I'm aware of). So do the conversions explicitly instead of transmuting. Fixes #2053
2023-06-28Merge #2062bors[bot]
2062: Disable the doc test for sys::personality::personality on aarch64 r=asomers a=asomers It's failing in CI, and we don't yet know why. Possibly the cloud provider just turned on seccomp. Issue #2060 Co-authored-by: Alan Somers <asomers@gmail.com>
2023-06-27Disable the doc test for sys::personality::personality on aarch64Alan Somers
It's failing in CI, and we don't yet know why. Possibly the cloud provider just turned on seccomp. Issue #2060
2023-06-17Haiku: `speed_t` is defined as `u8` for 32 and 64 bit systemsNiels Sascha Reedijk
2023-06-06Merge #2052bors[bot]
2052: Fix CI with the latest rustup r=asomers a=asomers Co-authored-by: Alan Somers <asomers@gmail.com> Co-authored-by: Ben Kimock <kimockb@gmail.com>
2023-06-05Clippy cleanup:Ben Kimock
fix the new clippy::non-minimal-cfg lint
2023-06-05Fix CI with the latest RustupAlan Somers
The latest Rustup does not allow the toolchain specification to be blank, which we were using. Fix it by ensuring that only one toolchain is ever installed in a given task, so we won't need to use the +$TOOLCHAIN with cargo.
2023-06-05Update CHANGELOG for patch release 0.26.2Alan Somers
[skip ci]
2023-05-22Fix warnings.Andrew Walbran
2023-05-22Use repr(transparent) for bitflags.Andrew Walbran
2023-05-22Update to bitflags 2.3.1.Andrew Walbran
This is a new major version and requires some code changes.
2023-05-22Use .bits() method rather than field for bitflags.Andrew Walbran
2023-05-21Merge #2009bors[bot]
2009: Add more detail for ptrace documentation r=asomers a=thomasqueirozb All functions are documented with the equivalent C call example except for `read`, `read_user`, `write` & `write_user`. I was looking for the function that used `PTRACE_PEEKDATA` and couldn't find it using the documentation and had to go to the source code to find it out. In hindsight, it's pretty obvious that it was read... But still I think it would be nice to have it documented Co-authored-by: Thomas de Queiroz Barros <38295417+thomasqueirozb@users.noreply.github.com>
2023-05-21Merge #2040bors[bot]
2040: timerfd: Add TFD_TIMER_CANCEL_ON_SET flag r=asomers a=apohrebniak Hi. This PR adds an TFD_TIMER_CANCEL_ON_SET flag to use with `timerfd` on Linux and Android Co-authored-by: Andrii Pohrebniak <andrii.pohrebniak@gmail.com>
2023-05-21Merge #2042bors[bot]
2042: Update memoffset to 0.9 r=asomers a=est31 Updates memoffset to version 0.9 Co-authored-by: est31 <MTest31@outlook.com>
2023-05-21Merge #2043bors[bot]
2043: Clippy cleanup: r=asomers a=asomers fix the new clippy::non_minimal_cfg lint Co-authored-by: Alan Somers <asomers@gmail.com>
2023-05-21Clippy cleanup:Alan Somers
fix the new clippy::non_minimal_cfg lint
2023-05-21Update memoffset to 0.9est31
2023-05-20timerfd: Add TFD_TIMER_CANCEL_ON_SET flagAndrii Pohrebniak
2023-05-20Merge #2029bors[bot]
2029: Remove 'static mut' usage in features::os::kernel_version. r=asomers a=zachs18 Resolves #2028 Note that this is (AFAICT) the first use of `Atomic*` types in `nix` (other than tests). However, this shouldn't be a portability issue, since `nix` is not `#![no_std]`, and (IIUC) [`std` requires](https://doc.rust-lang.org/std/sync/atomic/#portability) at least loads and stores of pointer-sized atomics (i.e. `AtomicUsize`), which is all this PR uses. Co-authored-by: Zachary S <zasample18+github@gmail.com>
2023-05-09Merge #2033bors[bot]
2033: remove unused mut from two variable declarations in sys/socket/mod.rs r=asomers a=inglorion This addresses diagnostics like: error: variable does not need to be mutable --> src/sys/socket/mod.rs:1537:13 | 1537 | let mut p = &mut mmsghdr.msg_hdr; Co-authored-by: Bob Haarman <inglorion@google.com>
2023-05-09remove unused mut from two variable declarations in sys/socket/mod.rsBob Haarman
This addresses diagnostics like: error: variable does not need to be mutable --> src/sys/socket/mod.rs:1537:13 | 1537 | let mut p = &mut mmsghdr.msg_hdr;
2023-04-29Remove 'static mut' usage in features::os::kernel_version.Zachary S
(re-commit for CI retry after rustix 0.37.18 release)
2023-04-26Merge #2026bors[bot]
2026: Update to published release of libc r=asomers a=atouchet Co-authored-by: Alex Touchet <alextouchet@outlook.com>
2023-04-25Update to crates.io release of libcAlex Touchet
2023-04-16Merge #2021bors[bot]
2021: Fixing link in rustdoc comments in User::from_name r=asomers a=austinkeeley Link text is correct but the URL goes to the wrong function. Probably just a copy/paste issue from the other function. Co-authored-by: Austin Keeley <austin.keeley@gmail.com>
2023-04-16Merge #2022bors[bot]
2022: Quiet Clippy::manual_slice_size_calculation lints r=asomers a=asomers Co-authored-by: Alan Somers <asomers@gmail.com>
2023-04-16Quiet a clippy::suspicious_doc_comments lintAlan Somers
2023-04-16Quiet Clippy::manual_slice_size_calculation lintsAlan Somers
2023-04-16Fixing linkAustin Keeley
2023-04-05Merge #2012bors[bot]
2012: Enable socket and select on redox r=asomers a=coolreader18 Co-authored-by: Noa <coolreader18@gmail.com>
2023-04-03Add CHANGELOG entryNoa
2023-04-02Merge #1999bors[bot]
1999: inotify: Add AsFd to allow using with epoll (issue #1998) r=asomers a=VorpalBlade This resolves issue #1998 and allows `Inotify` to be used by `Epoll` by adding AsFd. I'm not entirely sure about the unit test. Maybe it would be possible to do a more comperhensive check by contructing inotify using `from_raw_fd` and checking that I get the same value back. However, that would basically mean duplicating `Inotify::new` and that feels a bit pointless. Another option would be to create an integration test to combine `Inotify` and `Epoll`. Fixes #1998 Co-authored-by: Arvid Norlander <VorpalBlade@users.noreply.github.com>
2023-03-21Merge #1925bors[bot]
1925: fix: send ETH_P_ALL in htons format r=asomers a=tzneal Co-authored-by: Todd Neal <toddneal@protonmail.com>
2023-03-20fix: send ETH_P_ALL in htons formatTodd Neal
2023-03-13Enable select on redoxNoa
2023-03-13Enable socket on redoxNoa
2023-03-06Add more detail for ptrace documentationThomas de Queiroz Barros
2023-02-19inotify: Add AsFd to allow using with epoll (issue #1998)Arvid Norlander
2023-02-10Merge #1995bors[bot]
1995: Add `AT_EACCESS` to `AtFlags` on all platforms r=asomers a=MatteoNardi On Linux, I need the `AT_EACCESS` flag for `faccessat`: ``` AT_EACCESS Perform access checks using the effective user and group IDs. By default, faccessat() uses the real IDs (like access()). ``` ~~This commit is enabling it for all platforms but redox. I'm not really sure if this is correct of I should have just added a target_os = "linux". A did quick git grep -e AT_EACCESS -e 'AT_REMOVEDIR' on libc and it showed they're available on the same targets, so for consistence I just removed the cfg limitation.~~ CI was helpful and showed me I was wrong: it's undefined on android. Co-authored-by: Matteo Nardi <matteo@exein.io>
2023-02-10Merge #1943bors[bot]
1943: Rustier kqueue API r=rtzoeller a=asomers * Prefer methods instead of functions. * Create a newtype for a kqueue. * Document everything. * Deprecate EVFILT_SENDFILE, because it was never fully implemented upstream. * Add support to the libc_enum! macro to be able to deprecate variants. Co-authored-by: Alan Somers <asomers@gmail.com>
2023-02-09Rustier kqueue APIAlan Somers
* Prefer methods instead of functions. * Create a newtype for a kqueue. * Document everything. * Deprecate EVFILT_SENDFILE, because it was never fully implemented upstream. * Add support to the libc_enum! macro to be able to deprecate variants.
2023-02-09Merge #1967bors[bot]
1967: Added LOCAL_PEERPID/LocalPeerPid sockopt for macos r=asomers a=mitsuhiko macOS has a badly documented `LOCAL_PEERPID` sockopt that can be used to retrieve the PID of the connected peer. I intentionally only added this for macOS because I know it exists there, and I'm not sure about ios yet even if it exists there, it's doubtful that the PID information gets any use there. Co-authored-by: Armin Ronacher <armin.ronacher@active-4.com>
2023-02-09Merge #1991bors[bot]
1991: setgroups type mismatches on Solaris #1986 r=asomers a=gco Addresses #1986 Co-authored-by: gco <gco@jazzhaiku.com>
2023-02-01Enabled `AtFlags::AT_EACCESS` on all platforms but android and redoxMatteo Nardi
2023-01-31setgroups type mismatches on Solaris #1986gco
2023-01-27Merge #1978bors[bot]
1978: Null-check `libc::group` members before converting r=rtzoeller a=djkoloski This mirrors the approach used for the `From<&libc::passwd> for User` impl. Co-authored-by: David Koloski <djkoloski@gmail.com>