std.ps.fork

std.ps

fork() -> pid

Create a child process

Creates a child process by duplicating the calling process. Returns 0 in the child process and the child's PID in the parent process.

The child keeps the caller's signal handlers and its signal mask. Under a lev loop that holds a signal through on_signal, the child holds it blocked too, and a kill with that signal does not end it. A program the child starts through exec starts clean.