summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-12-19Update cross-compilation Rust version to 1.40.0Tamir Duberstein
This was missed in d36353701341df9cfffb4fc4e88c002698d2deda.
2020-12-19Merge #1331bors[bot]
1331: feat(sys): High-level personality(2) wrappers r=asomers a=woodruffw Adds a high level `Persona` bitflags enum, as well as `personality::get()` and `personality::set()` for interacting with `libc::personality()`. Closes #1330. See also https://github.com/rust-lang/libc/pull/1974. Co-authored-by: William Woodruff <william@trailofbits.com>
2020-12-18Merge #1365bors[bot]
1365: Fix duplicate entry in bors.toml r=asomers a=asomers Also, sort the entries alphabetically, since that's how Github displays them. Co-authored-by: Alan Somers <asomers@gmail.com>
2020-12-18Fix duplicate entry in bors.tomlAlan Somers
Also, sort the entries alphabetically, since that's how Github displays them.
2020-12-15feat(sys): High-level personality(2) wrappersWilliam Woodruff
Adds a high level `Persona` bitflags enum, as well as `personality::get()` and `personality::set()` for interacting with `libc::personality()`.
2020-12-14Merge pull request #1362 from asomers/no_socklevelAlan Somers
Remove SockLevel
2020-12-14Remove SockLevelAlan Somers
It's been unused since PR #133
2020-12-14Merge pull request #1358 from asomers/rust_1.40.0Alan Somers
Raise MSRV to 1.40.0
2020-12-14Ignore failures of test_aio_suspend on macosAlan Somers
On Cirrus-CI, this test frequently fails with EINVAL. The error goes away if I add a line of debugging, so it's probably a timing issue. But I can't debug it myself. Issue #1361
2020-12-10Remove a workaround for an old Musl bugAlan Somers
In older versions of Musl, ttyname_r would wrongly return ENOTTY instead of EBADF. We expected that bug in our test suite. But Rust 1.37.0 updated Musl to 1.1.22, which fixes the problem. This change reverts our workaround. https://www.openwall.com/lists/musl/2018/09/15/2 https://github.com/rust-lang/rust/commit/aaf66987931dfe06a547b9f68cb709e9b6265b5c
2020-12-10Merge pull request #1359 from asomers/no_travis_badgeAlan Somers
[skip ci] Update docs and build badges for the Travis -> Cirrus move
2020-12-10[skip ci] Update docs and build badges for the Travis -> Cirrus moveAlan Somers
2020-12-10Raise MSRV to 1.40.0Alan Somers
This will shortly be needed for Fuchsia support.
2020-12-09Merge pull request #1355 from asomers/alarm_doc_testAlan Somers
Fix intermittency in the doc test for alarm
2020-12-09Fix intermittency in the doc test for alarmAlan Somers
On Cirrus CI, this test would sometimes fail, probably due to pause being awoken by SIGRT_1. sigwait is a superior alternative to pause. Fixes #1354
2020-12-09Merge pull request #1353 from asomers/test_reliability2Alan Somers
Fix intermittency in some tests
2020-12-09Ignore the execve tests on muslAlan Somers
On Cirrus-CI, these tests frequently segfault. It's probably indicative of a real bug, not just a problem in the tests. But for now we need to skip them to get CI working. Issue #555
2020-12-08Fix unreliability in sys::test_aio::test_aio_suspendAlan Somers
On OSX, this test has begun to fail in CI on OSX. Presumably it's because aio_suspend was getting interrupted by a signal.
2020-12-08Fix a race in the test_unistd::test_fchown testAlan Somers
The test was assuming that once dropped, a temporary file's file descriptor would be invalid. But it might not be, because another file might be opened with the same file descriptor. Instead, use an obviously invalid file descriptor.
2020-12-07Merge pull request #1350 from asomers/cirrus4allAlan Somers
Switch all builds from Travis to Cirrus
2020-12-07Fix a use-after-free in execve_test_factoryAlan Somers
Ensure that the exec functions' arguments are valid for 'static. Previously they were short-lived temporaries.
2020-12-06Switch all builds from Travis to CirrusAlan Somers
Travis has been super-slow lately (> 6 hours per build). Cirrus is much faster: about 20 minutes. Cirrus also has slightly better test coverage, mainly because it doesn't use SECCOMP. Also, * Fix the Redox CI build. The old Travis configuration didn't actually build for Redox, so we never noticed that Redox can't be built with a stable compiler. Thanks to @coolreader18 for finding this. * Disable the udp_offload tests on cross-tested platforms. These tests are failing with ENOPROTOOPT in Cirrus-CI. I suspect it's due to a lack of support in QEMU. These tests were skipped on Travis because its kernel was too old. * Fix require_kernel_version on Cirrus-CI. Cirrus reports the Linux kernel version as 4.19.112+, which the semver crate can't handle. * Fix test_setfsuid on Cirrus. When run on Cirrus, it seems like the file in /tmp gets deleted as soon as it's closed. Probably an overzealous temporary file cleaner. Use /var/tmp, because no temporary file cleaner should run in there. * Skip mount tests on Cirrus. They fail for an unknown reason. Issue #1351 * Skip the AF_ALG tests on Cirrus-CI Issue #1352
2020-12-06Handle SIGRT_1 in test_alarmAlan Somers
When run in Cirrus-CI's environment, the tests generate copious SIGRT_1 signals. This commit ensures that test_alarm will ignore them.
2020-12-06Make the poll tests resilient against signalsAlan Somers
When run in Cirrus-CI's environment, the tests generate copious SIGRT_1 signals. This commit ensures that the poll tests will retry on EINTR.
2020-12-06Disable clock_getres on redoxNoah
2020-12-06Demote i686-apple-darwin to Tier 2Alan Somers
It's deprecated by Xcode, and the version of Xcode installed by Cirrus-CI doesn't include 32 bit libraries.
2020-11-28[skip ci] Add v0.19.1 release notes to CHANGELOGAlan Somers
2020-11-29Merge #1345bors[bot]
1345: Disable test-aio-drop in GNU environments r=asomers a=asomers This test occasionally fails in Travis on x86_64-unknown-linux-gnu. The failure takes the form of the test executable receiving a random signal. Sometimes SIGHUP, sometimes SIGKILL, etc. I think this must be a bug in glibc, even though I can't reproduce it in my development environment. But it interferes with CI too much to leave enabled. Co-authored-by: Alan Somers <asomers@gmail.com>
2020-11-28[skip ci] update CHANGELOG for PR #1341Alan Somers
2020-11-28Merge #1341bors[bot]
1341: Fix recvmmsg(2) implementation r=asomers a=codeslinger There were two problems discovered with the `recvmmsg(2)` implementation that this changeset attempts to fix: 1. As mentioned in nix-rust/issues/1325, `recvmmsg(2)` can return fewer messages than requested, and 2. Passing the return value of `recvmmsg(2)` as the number of bytes in the messages received is incorrect. This changeset incorporates the proposed fix from nix-rust/issues/1325, as well as passing the correct value (`mmsghdr.msg_len`) for the number of bytes in a given message. Co-authored-by: Toby DiPasquale <toby@cbcg.net>
2020-11-28Disable test-aio-drop in GNU environmentsAlan Somers
This test occasionally fails in Travis on x86_64-unknown-linux-gnu. The failure takes the form of the test executable receiving a random signal. Sometimes SIGHUP, sometimes SIGKILL, etc. I think this must be a bug in glibc, even though I can't reproduce it in my development environment. But it interferes with CI too much to leave enabled.
2020-11-27Fix recvmmsg(2) implementationToby DiPasquale
There were two problems discovered with the `recvmmsg(2)` implementation that this changeset attempts to fix: 1. As mentioned in nix-rust/issues/1325, `recvmmsg(2)` can return fewer messages than requested, and 2. Passing the return value of `recvmmsg(2)` as the number of bytes in the messages received is incorrect. This changeset incorporates the proposed fix from nix-rust/issues/1325, as well as passing the correct value (`mmsghdr.msg_len`) for the number of bytes in a given message.
2020-11-19Merge #1337bors[bot]
1337: Add docs.rs target list r=asomers a=myfreeweb ref: https://blog.rust-lang.org/2020/03/15/docs-rs-opt-into-fewer-targets.html Makes sense to build docs for all supported OSes (BSD, Redox) rather than completely empty docs for Windows :) Co-authored-by: myfreeweb <greg@unrelenting.technology>
2020-11-17Add docs.rs target listmyfreeweb
ref: https://blog.rust-lang.org/2020/03/15/docs-rs-opt-into-fewer-targets.html
2020-11-16Merge #1332bors[bot]
1332: Suppress temporary libc deprecations r=asomers a=tamird See individual commits. This PR is an alternative to #1329. @asomers Co-authored-by: Tamir Duberstein <tamird@gmail.com>
2020-11-15Suppress time_t musl "deprecation"Tamir Duberstein
See https://github.com/rust-lang/libc/issues/1848 in which this type is changing from i32 to i64; the change is being announced via this deprecation.
2020-11-15Suppress af_alg_iv "deprecation"Tamir Duberstein
See https://github.com/rust-lang/libc/issues/1501 in which this type's trait implementations are being removed; the change is being announced via this deprecation.
2020-10-18Merge #1318bors[bot]
1318: KEEPCNT/KEEPINTVL aren't available on OpenBSD. r=asomers a=ltratt Without this commit, nix doesn't currently compile on OpenBSD. Some keepalive settings can be set globally, but not per-socket (see e.g. https://bugzilla.mozilla.org/show_bug.cgi?id=970550 for some digging into this). Since it seems that NetBSD and DragonflyBSD have these settings, it makes more sense to only exclude them on OpenBSD rather than include them on (pretty much every) other operating systems. Co-authored-by: Laurence Tratt <laurie@tratt.net>
2020-10-18KEEPCNT/KEEPINTVL aren't available on OpenBSD.Laurence Tratt
Without this commit, nix doesn't currently compile on OpenBSD. Some keepalive settings can be set globally, but not per-socket (see e.g. https://bugzilla.mozilla.org/show_bug.cgi?id=970550 for some digging into this). Since it seems that NetBSD and DragonflyBSD have these settings, it makes more sense to only exclude them on OpenBSD rather than include them on (pretty much every) other operating systems.
2020-10-16Merge #1316bors[bot]
1316: update require_kernel_version string to handle "_" in version string r=asomers a=ritzk test code breaks on fc333 ``` $ cargo test failures: ---- sys::test_socket::recvfrom::udp_offload::gro stdout ---- thread 'sys::test_socket::recvfrom::udp_offload::gro' panicked at 'called `Result::unwrap()` on an `Err` value: ParseError("Extra junk after valid version: _64")', test/sys/test_socket.rs:292:13 ``` this is due underscore in release string( arch/x86_64), which is not supported by semver. ``` $ uname -r 5.8.14-300.fc33.x86_64 ``` Co-authored-by: Ritesh Khadgaray <khadgaray@gmail.com>
2020-10-16update require_kernel_version to handle "_" in version stringRitesh Khadgaray
test code breaks on fedora 33 ``` $ cargo test failures: ---- sys::test_socket::recvfrom::udp_offload::gro stdout ---- thread 'sys::test_socket::recvfrom::udp_offload::gro' panicked at 'called `Result::unwrap()` on an `Err` value: ParseError("Extra junk after valid version: _64")', test/sys/test_socket.rs:292:13 ``` this is due underscore in release string( arch/x86_64), which is not supported by semver. ``` $ uname -r 5.8.14-300.fc33.x86_64 ``` Replace the underscore with hypen to provide a consistent sematic.
2020-10-15Merge #1313bors[bot]
1313: Update to cfg-if 1.0 r=asomers a=mbrubeck Co-authored-by: Matt Brubeck <mbrubeck@limpet.net>
2020-10-15Update to cfg-if 1.0Matt Brubeck
2020-10-13Merge #1306bors[bot]
1306: Add wrapper for mremap r=asomers a=sporksmith Fixes #1295 Co-authored-by: Jim Newsome <jnewsome@torproject.org>
2020-10-13Add wrapper for mremapJim Newsome
2020-10-12add Cirrus CI badge to readmeMax Blachman
2020-10-12Merge #1307bors[bot]
1307: Release v0.19.0. r=kamalmarhubi a=qwandor-google I'd like to get a new version of the crate released including #1301 so that I can get the vsock crate building on Android, and get both imported into the Android tree. Co-authored-by: Andrew Walbran <qwandor@google.com>
2020-10-10Merge #1283bors[bot]
1283: Add support for TCP_KEEPCNT and TCP_KEEPINTVL TCP keepalive options. r=asomers a=yoav-steinberg Co-authored-by: Yoav Steinberg <yoav@monfort.co.il>
2020-10-10Add support for TCP_KEEPCNT and TCP_KEEPINTVL TCP keepalive options.Yoav Steinberg
2020-10-10Merge #1303bors[bot]
1303: Renable the ScmTimestamp test on FreeBSD i386 r=posborne a=asomers The relevant bug was fixed in 11.3-RELEASE https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=222039 Co-authored-by: Alan Somers <asomers@gmail.com>