
























>> So perhaps if spawning children needs to be extended on Linux, it should be around consuming child terminations, not spawning.
> This should be sorted now by using pidfds to track status and the PIDFD_GET_INFO ioctl, which should always return the exit status in recent kernels, IIRC
This is nice. I wasn't aware. Actually there is much simpler alternative I forgot about. By using 0 for exit signal field of clone, child's terminations get effectively hidden from ~most uses of wait/waitpid/etc. Doesn't need pidfd and doesn't need modern Linux kernel.
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。