This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -149,8 +149,7 @@ pub trait CommandExt: Sealed {
149149 /// The pidfd can be retrieved from the child with [`pidfd`] or [`take_pidfd`].
150150 ///
151151 /// A pidfd will only be created if it is possible to do so
152- /// in a guaranteed race-free manner (e.g. if the `clone3` system call
153- /// is supported). Otherwise, [`pidfd`] will return an error.
152+ /// in a guaranteed race-free manner. Otherwise, [`pidfd`] will return an error.
154153 ///
155154 /// If a pidfd has been successfully created and not been taken from the `Child`
156155 /// then calls to `kill()`, `wait()` and `try_wait()` will use the pidfd
Original file line number Diff line number Diff line change @@ -147,8 +147,7 @@ impl Command {
147147 #[ cfg( not( target_os = "linux" ) ) ]
148148 let pidfd = -1 ;
149149
150- // Safety: We obtained the pidfd from calling `clone3` with
151- // `CLONE_PIDFD` so it's valid an otherwise unowned.
150+ // Safety: We obtained the pidfd (on Linux) using SOCK_SEQPACKET, so it's valid.
152151 let mut p = unsafe { Process :: new ( pid, pidfd) } ;
153152 let mut bytes = [ 0 ; 8 ] ;
154153
You can’t perform that action at this time.
0 commit comments