Sun Studio 12: C User's Guide

C.1.12 Library Functions (J.3.12)

The status made available to wait(3C) or waitpid(3C) by abort will be that of a process terminated by the SIGABRT signal. See the abort(3C), exit(1), and _Exit(2) man pages.

The termination status returned by exit, or _Exit, depends on the what the parent process of the calling process is doing.

If the parent process of the calling process is executing a wait(3C), wait3(3C), waitid(2), or waitpid(3C), and has neither set its SA_NOCLDWAIT flag nor set SIGCHLD to SIG_IGN, it is notified of the calling process’s termination and the low-order eight bits (that is, bits 0377) of status are made available to it. If the parent is not waiting, the child’s status is made available to it when the parent subsequently executes wait(), wait3(), waitid(), or waitpid().