rust/library/std/src/sys
bors 6639672554 Auto merge of #117156 - jmillikin:os-unix-socket-ext, r=Amanieu,dtolnay
Convert `Unix{Datagram,Stream}::{set_}passcred()` to per-OS traits

These methods are the pre-stabilized API for obtaining peer credentials from an `AF_UNIX` socket, part of the `unix_socket_ancillary_data` feature.

Their current behavior is to get/set one of the `SO_PASSCRED` (Linux), `LOCAL_CREDS_PERSISTENT` (FreeBSD), or `LOCAL_CREDS` (NetBSD) socket options. On other targets the `{set_}passcred()` methods do not exist.

There are two problems with this approach:

1. Having public methods only exist for certain targets isn't permitted in a stable `std` API.

2. These options have generally similar purposes, but they are non-POSIX and their details can differ in subtle and surprising ways (such as whether they continue to be set after the next call to `recvmsg()`).

Splitting into OS-specific extension traits is the preferred solution to both problems.
2024-03-11 07:46:01 +00:00
..
locks Windows: Implement mutex using futex 2024-03-05 00:19:42 +00:00
os_str Move OsStr::slice_encoded_bytes validation to platform modules 2024-01-21 19:51:49 +01:00
pal Auto merge of #117156 - jmillikin:os-unix-socket-ext, r=Amanieu,dtolnay 2024-03-11 07:46:01 +00:00
path std: move path into sys 2024-02-08 12:51:35 +01:00
personality std: move personality implementation out of PAL 2024-01-13 18:30:44 +01:00
thread_local std: move thread local implementation to sys 2024-02-28 19:12:29 +01:00
cmath.rs Make cmath.rs a single file 2024-02-07 12:02:24 -03:00
mod.rs std: move thread local implementation to sys 2024-02-28 19:12:29 +01:00