[libc-commits] [libc] [libc] Implement waitid in sys/wait (PR #227815)
Pavel Labath via libc-commits
libc-commits at lists.llvm.org
Fri Oct 9 02:42:24 PDT 2026
================
@@ -55,6 +56,22 @@ void fork_and_wait4_normal_exit() {
ASSERT_TRUE(WIFEXITED(status));
}
+void fork_and_waitid_normal_exit() {
+ pid_t pid = LIBC_NAMESPACE::fork();
+ if (pid == 0)
+ return; // Just end without any thing special.
----------------
labath wrote:
Otherwise, the forked child will continue executing all the remaining tests.
```suggestion
if (pid == 0)
LIBC_NAMESPACE::internal::exit(0);
```
https://github.com/llvm/llvm-project/pull/227815
More information about the libc-commits
mailing list