summaryrefslogtreecommitdiff
path: root/CHANGELOG.md
AgeCommit message (Collapse)Author
2021-05-13Use https instead of httpRyan Zoeller
2021-04-26constify from_raw and as_raw for Uid, Gid and PidWolfgang Bumiller
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2021-04-08Merge #1402bors[bot]
1402: Support TIMESTAMPNS r=asomers a=WiSaGaN This adds support of linux TIMESTAMPNS. The code is mostly copied paste from https://github.com/nix-rust/nix/pull/663 Co-authored-by: Lu, Wangshan <wisagan@gmail.com>
2021-04-08Support TIMESTAMPNS for linuxLu, Wangshan
2021-04-07Fix spurious errors using `sendmmsg` with multiple cmsgsYuchen Wu
Before this fix, the buffer that holds cmsgs may move due to the resize() call. That causes msg_hdr pointing to invalid memory, which ends up breaking the sendmmsg() call, resulting in EINVAL. This change fixes it by avoiding re-allocating the buffers.
2021-03-05Allow sockaddr_ll size mismatchJustin Ossevoort
Apparently the Linux kernel can return smaller sizes when the value in the last element of sockaddr_ll (`sll_addr`) is smaller than the declared size of that field.
2021-03-04Remove accept4 on Android armAlan Somers
libc removed it in version 0.2.87. https://github.com/rust-lang/libc/pull/2079
2021-02-20pty: Make forkpty() unsafeTavian Barnes
After the child returns from a fork() of a multi-threaded process, it is undefined behaviour to call non-async-signal-safe functions according to POSIX. Since forkpty() is implemented in terms of fork(), those restrictions should apply to it too.
2021-02-20[skip ci] add a new CHANGELOG sectionAlan Somers
2021-02-20Prepare for release 0.20.0Alan Somers
2021-02-20[skip ci] reformat CHANGELOGAlan Somers
2021-02-20Merge branch 'master' into timerfd-file-leakAlan Somers
2021-02-16Close file descriptor on drop in TimerFdChristopher Dumoulin
2021-02-15Log x32 fixesнаб
2021-02-15Dir: Implement `IntoIterator` for `Dir`William Manley
This is useful to allow returning an iterator based on a directory iterator without needing a self-referential struct.
2021-02-13Merge #1382bors[bot]
1382: Don't implement Clone on Dir, SignalFd, and PtyMaster r=asomers a=asomers Since they close their file descriptors on Drop, it's almost impossible to use Clone without creating a double-close situation. Also, check for EBADF in SignalFd::drop and Dir::drop. Co-authored-by: Alan Somers <asomers@gmail.com>
2021-02-07Don't implement Clone on Dir, SignalFd, and PtyMasterAlan Somers
Since they close their file descriptors on Drop, it's almost impossible to use Clone without creating a double-close situation. Also, check for EBADF in SignalFd::drop and Dir::drop.
2021-02-07add passwords to GroupsBen Linsay
2021-02-02Define *_MAGIC filesystem constants on Linux s390xJakob Naucke
Since rust-lang/libc is now using the correct data type on s390x (c_uint) for statfs constants, the s390x exemptions in the statfs MAGIC definitions like EXT4_SUPER_MAGIC can be removed. Signed-off-by: Jakob Naucke <jakob.naucke@ibm.com>
2021-01-04Add support for when receiving packetsJustin Ossevoort
2020-12-19unistd: Add getpeereid(3)William Woodruff
Closes #1339.
2020-12-19Add fuchsia supportAmanda Tait
Allow nix to compile on Fuchsia by conditionally avoiding libc functionality that does not exist for Fuchsia.
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-14Remove SockLevelAlan Somers
It's been unused since PR #133
2020-12-10Raise MSRV to 1.40.0Alan Somers
This will shortly be needed for Fuchsia support.
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-28[skip ci] update CHANGELOG for PR #1341Alan Somers
2020-10-13Add wrapper for mremapJim Newsome
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-10Add support for TCP_KEEPCNT and TCP_KEEPINTVL TCP keepalive options.Yoav Steinberg
2020-10-06Release v0.19.0.Andrew Walbran
2020-10-04Support vsock on Android as well as Linux.Andrew Walbran
Fix deprecation warning from libc update.
2020-10-03Merge #1300bors[bot]
1300: Add PTRACE_SYSEMU and PTRACE_SYSEMU_SINGLESTEP support r=asomers a=voidc Closes #1249. I think @jabedude was working on this, but as there was no progress since May I went ahead and implemented it myself. I'm not completely sure about the cfg gates. Could we enable the functions for more targets? I'm also open for suggestions of better names for the new functions. Co-authored-by: Dominik Stolz <d.stolz@tum.de>
2020-10-03Merge #1293bors[bot]
1293: Mark nix::unistd::fork as unsafe. r=asomers a=vi Fix tests. No change in documentation. Resolves #1030. Don't forget to bump major version number to `0.19`. Co-authored-by: Vitaly _Vi Shukela <vi0oss@gmail.com>
2020-10-03Add PTRACE_SYSEMU and PTRACE_SYSEMU_SINGLESTEP supportDominik Stolz
2020-09-28Added clock_gettime, clock_getres, clock_settime, clock_getcpuclockidDaniil Bondarev
2020-09-20Add CHANGELOG.md entry about unsafe fork.Vitaly _Vi Shukela
2020-08-22Merge branch 'master' into musl_seekAlan Somers
2020-08-22Add changelog entryAmanieu d'Antras
2020-08-22Merge #1278bors[bot]
1278: Allow both &[CString] and &[&CStr] for sequence args in unistd r=asomers a=youknowone I am new to this project, so I wonder this kind of change is acceptable for the project or not. I agree taking `&[&CStr]` is the ideal way for the functions. But unfortunately, when users generate `CString`s from `&str`, they may get `&[CString]` rather than `&[&CStr]` Unlike single `CString` to `&CStr` argument, there is no easy way to convert `&[CString]` to `&[&CStr]` without creating new vector. By changing the type from `&[&CStr]` to `&[AsRef<CStr>]`, the args now can take both `&[CString]` and `&[&CStr]` without changing that much from nix. Co-authored-by: Jeong YunWon <jeong@youknowone.org>
2020-08-18Add Netlink Protocol Families to SockProtocol enumsinkingpoint
Currently the SockProtocol enum is rather scarce. This commit adds the Netlink protocols defined in netlink(7) to the SockProtocol enum allowing us to use the Nix socket library for more indepth Netlink work
2020-07-28Allow both &[CString] and &[&CStr] for sequence argsJeong YunWon
2020-07-26Release version 0.18.0Alan Somers
2020-07-26Support nullable timeout in ppollMikail Bagishov
2020-07-07Adding an implementation and some basic tests for timerfd.Vincent Dagonneau
Removed support for timerfd on Android as it seems to have been deprecated? See https://android.googlesource.com/platform/development/+/73a5a3b/ndk/platforms/android-20/include/sys/timerfd.h or https://github.com/rust-lang/libc/issues/1589 Removed the public status of `TimerSpec`, as it should not be exposed to the user. Implemented `FromRawFd` for `TimerFd` as it already implements `AsRawFd`. Addressed comments from the latest code review: - Removed upper bound assertions on timer expirations in tests. - Made the main example runnable and added code to show how to wait for the timer. - Refactored `ClockId` to use `libc_enum`. - Added comments for all public parts of the module. - Wrapped to 80 cols. - Changed the size of the buffer in the tests to the minimum required. * Ran rustfmt. * Added a `From` implementation for `libc::timespec` -> `TimeSpec`. * Reworked the example with the new changes and changed the timer from 5 to 1 second. * Added a constructor for a 0-initialized `TimerSpec`. * Added a new method to get the timer configured expiration (based on timerfd_gettime). * Added an helper method to unset the expiration of the timer. * Added a `wait` method to actually read from the timer. * Renamed `settime` into just `set`. * Refactored the tests and added a new one that tests both the `unset` and the `get` method. Modified CHANGELOG.
2020-07-04Expose IP_PKTINFO Control Message on AndroidBruno Tavares
The commit https://github.com/nix-rust/nix/pull/1222 added the very useful Ipv4PktInfo to allow `sendmsg` to define the origin of the ip. Unfortunattely, it didn't add the struct to Android target devices as well. This commit adds the `target_os = "android"` checks on the same place to allow the compilation to work for the following archs tested: - `cross build --target aarch64-linux-android` - `cross build --target x86_64-linux-android` - `cross build --target armv7-linux-androideabi` Also introduces iOS to allow using on libs for those platforms
2020-07-03implement ttynameJesse Luehrs
2020-07-03Merge #1244bors[bot]
1244: Clippy cleanup r=asomers a=asomers Reported-by: Clippy Co-authored-by: Alan Somers <asomers@gmail.com>
2020-07-02Drop support for powerpc64-unknown-linux-gnuAlan Somers
The build is failing due to no fault of Nix. Even rust-embedded/cross has given up on fixing it, so there's no hope for us. Fixes #1267 See also https://github.com/rust-embedded/cross/pull/440