From 79e52b3f1ea5038de95372b45ffcb523d6b462a2 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Mon, 8 Nov 2021 17:28:02 +0000 Subject: unix::ExitStatusExt: Correct reference to _exit system call As discussed here https://github.com/rust-lang/rust/pull/88300#issuecomment-936085371 exit is (conventionally) a library function, with _exit being the actual system call. I have checked the other references and they say "if the process terminated by calling `exti`". I think despite the slight imprecision (strictly, it should read iff ... `_exit`), this is clearer. Anyone who knows about the distinction between `exit` and `_exit` will not be confused. `_exit` is the correct traditional name for the system call, despite Linux calling it `exit_group` or `exit`: https://www.freebsd.org/cgi/man.cgi?query=_exit&sektion=2&n=1 Signed-off-by: Ian Jackson --- library/std/src/os/unix/process.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'library/std/src/os/unix') diff --git a/library/std/src/os/unix/process.rs b/library/std/src/os/unix/process.rs index 286a7c3b386..f5732161575 100644 --- a/library/std/src/os/unix/process.rs +++ b/library/std/src/os/unix/process.rs @@ -207,7 +207,7 @@ impl CommandExt for process::Command { /// [`ExitStatusError`](process::ExitStatusError). /// /// On Unix, `ExitStatus` **does not necessarily represent an exit status**, as -/// passed to the `exit` system call or returned by +/// passed to the `_exit` system call or returned by /// [`ExitStatus::code()`](crate::process::ExitStatus::code). It represents **any wait status** /// as returned by one of the `wait` family of system /// calls. -- cgit 1.4.1-3-g733a5