nix v0.10.0 Release Notes

Release Date: 2018-01-26 // about 6 years ago
  • ➕ Added

    • ➕ Added specialized wrapper: sys::ptrace::step (#852)
    • Added AioCb::from_ptr and AioCb::from_mut_ptr (#820)
    • ➕ Added specialized wrappers: sys::ptrace::{traceme, syscall, cont, attach}. Using the matching routines with sys::ptrace::ptrace is now deprecated.
    • ➕ Added nix::poll module for all platforms (#672)
    • ➕ Added nix::ppoll function for FreeBSD and DragonFly (#672)
    • ➕ Added protocol families in AddressFamily enum. (#647)
    • ➕ Added the pid() method to WaitStatus for extracting the PID. (#722)
    • ➕ Added nix::unistd:fexecve. (#727)
    • 🔦 Expose uname() on all platforms. (#739)
    • 🔦 Expose signalfd module on Android as well. (#739)
    • ➕ Added nix::sys::ptrace::detach. (#749)
    • ➕ Added timestamp socket control message variant: nix::sys::socket::ControlMessage::ScmTimestamp (#663)
    • ➕ Added socket option variant that enables the timestamp socket control message: nix::sys::socket::sockopt::ReceiveTimestamp (#663)
    • ➕ Added more accessor methods for AioCb (#773)
    • ➕ Add nix::sys::fallocate ([#768](https:://github.com/nix-rust/nix/pull/768))
    • ➕ Added nix::unistd::mkfifo. (#602)
    • Added ptrace::Options::PTRACE_O_EXITKILL on Linux and Android. (#771)
    • Added nix::sys::uio::{process_vm_readv, process_vm_writev} on Linux (#568)
    • ➕ Added nix::unistd::{getgroups, setgroups, getgrouplist, initgroups}. (#733)
    • ➕ Added nix::sys::socket::UnixAddr::as_abstract on Linux and Android. (#785)
    • ➕ Added nix::unistd::execveat on Linux and Android. (#800)
    • ➕ Added the from_raw() method to WaitStatus for converting raw status values to WaitStatus independent of syscalls. (#741)
    • ➕ Added more standard trait implementations for various types. (#814)
    • ➕ Added sigprocmask to the signal module. (#826)
    • ➕ Added nix::sys::socket::LinkAddr on Linux and all bsdlike system. (#813)
    • Add socket options for IP_TRANSPARENT / BIND_ANY. (#835)

    🔄 Changed

    • 🔦 Exposed the mqueue module for all supported operating systems. (#834)
    • 👉 Use native pipe2 on all BSD targets. Users should notice no difference. (#777)
    • 📇 Renamed existing ptrace wrappers to encourage namespacing (#692)
    • Marked sys::ptrace::ptrace as unsafe.
    • 🔄 Changed function signature of socket() and socketpair(). The protocol argument has changed type from c_int to SockProtocol. It accepts a None value for default protocol that was specified with zero using c_int. (#647)
    • Made select easier to use, adding the ability to automatically calculate the nfds parameter using the new FdSet::highest (#701)
    • 🔦 Exposed unistd::setresuid and unistd::setresgid on FreeBSD and OpenBSD (#721)
    • 🔨 Refactored the statvfs module removing extraneous API functions and the statvfs::vfs module. Additionally (f)statvfs() now return the struct directly. And the returned Statvfs struct now exposes its data through accessor methods. (#729)
    • 👍 The addr argument to madvise and msync is now *mut to better match the libc API. (#731)
    • shm_open and shm_unlink are no longer exposed on Android targets, where they are not officially supported. (#731)
    • MapFlags, MmapAdvise, and MsFlags expose some more variants and only officially-supported variants are provided for each target. (#731)
    • Marked pty::ptsname function as unsafe (#744)
    • ⚡️ Moved constants ptrace request, event and options to enums and updated ptrace functions and argument types accordingly. (#749)
    • AioCb::Drop will now panic if the AioCb is still in-progress (#715)
    • 🐧 Restricted nix::sys::socket::UnixAddr::new_abstract to Linux and Android only. (#785)
    • 🚚 The ucred struct has been removed in favor of a UserCredentials struct that contains only getters for its fields. (#814)
    • Both ip_mreq and ipv6_mreq have been replaced with IpMembershipRequest and Ipv6MembershipRequest. (#814)
    • ✂ Removed return type from pause. (#829)
    • 🔄 Changed the termios APIs to allow for using a u32 instead of the BaudRate enum on BSD platforms to support arbitrary baud rates. See the module docs for nix::sys::termios for more details. (#843)

    🛠 Fixed

    • 🛠 Fix compilation and tests for OpenBSD targets (#688)
    • 🛠 Fixed error handling in AioCb::fsync, AioCb::read, and AioCb::write. It is no longer an error to drop an AioCb that failed to enqueue in the OS. (#715)
    • 🛠 Fix potential memory corruption on non-Linux platforms when using sendmsg/recvmsg, caused by mismatched msghdr definition. (#648)

    ✂ Removed

    • AioCb::from_boxed_slice has been removed. It was never actually safe. Use from_bytes or from_bytes_mut instead. (#820)
    • 🚚 The syscall module has been removed. This only exposed enough functionality for memfd_create() and pivot_root(), which are still exposed as separate functions. (#747)
    • The Errno variants are no longer reexported from the errno module. Errno itself is no longer reexported from the crate root and instead must be accessed using the errno module. (#696)
    • Removed MS_VERBOSE, MS_NOSEC, and MS_BORN from MsFlags. These are internal kernel flags and should never have been exposed. (#814)