Index: phpdoc/en/functions/pcntl.xml diff -u phpdoc/en/functions/pcntl.xml:1.1 phpdoc/en/functions/pcntl.xml:1.2 --- phpdoc/en/functions/pcntl.xml:1.1 Fri Sep 14 16:57:26 2001 +++ phpdoc/en/functions/pcntl.xml Fri Sep 21 17:07:38 2001 @@ -1,5 +1,5 @@ - + Process Control Functions PCNTL @@ -182,7 +182,41 @@ - + + + + + pcntl_signal + Installs a signal handler + + + Description + + + bool pcntl_signal + int signo + mixed handle + + + + The pcntl_signal function installs a new + signal handler for the signal indicated by + signo. The signal handler is set to + handler which may be the name of a user + created function, or either of the two global constants SIG_IGN + or SIG_DFL. + + + pcntl_signal returns &true; on success or + &false; on failure. + + + See also pcntl_fork and + pcntl_waitpid. + + + + @@ -218,44 +252,41 @@ The value of pid can be one of the following: - - - < -1 - - - wait for any child process whose process group ID is equal to - the absolute value of pid. - - - - - -1 - - - wait for any child process; this is the same behaviour that - the wait function exhibits. - - - - - 0 - - - wait for any child process whose process group ID is equal to - that of the calling process. - - - - - > 0 - - - wait for the child whose process ID is equal to the value of - pid. - - - - +

+ possible values for <parameter>pid</parameter> + + + + < -1 + + wait for any child process whose process group ID is equal to + the absolute value of pid. + + + + -1 + + wait for any child process; this is the same behaviour that + the wait function exhibits. + + + + 0 + + wait for any child process whose process group ID is equal to + that of the calling process. + + + + > 0 + + wait for the child whose process ID is equal to the value of + pid. + + + + +
pcntl_waitpid will store status information @@ -271,26 +302,27 @@ The value of options is the value of zero or more of the following two global constants - ORed together: - - - WNOHANG - - - return immediately if no child has exited. - - - - - WUNTRACED - - - return for children which are stopped, and whose status has - not been reported. - - - - + OR'ed together: + + possible values for <parameter>options</parameter> + + + + WNOHANG + + return immediately if no child has exited. + + + + WUNTRACED + + return for children which are stopped, and whose status has + not been reported. + + + + +
See also pcntl_fork, @@ -306,35 +338,199 @@ - + - pcntl_signal - Installs a signal handler + pcntl_wexitstatus + + Returns the return code of a terminated child + Description - bool pcntl_signal - int signo - mixed handle + int pcntl_wexitstatus + int status - The pcntl_signal function installs a new - signal handler for the signal indicated by - signo. The signal handler is set to - handler which may be the name of a user - created function, or either of the two global constants SIG_IGN - or SIG_DFL. + Returns the return code of a terminated child. This function is + only useful if pcntl_wifexited returned + &true;. - pcntl_signal returns &true; on success or - &false; on failure. + The parameter status is the status + parameter supplied to a successfull call to + pcntl_waitpid. - See also pcntl_fork and + See also pcntl_waitpid and + pcntl_wifexited. + + + + + + + + pcntl_wifexited + + Returns &true; if status code represents a successful exit + + + + Description + + + int pcntl_wifexited + int status + + + + Returns &true; if the child status code represents a successful + exit. + + + The parameter status is the status + parameter supplied to a successfull call to + pcntl_waitpid. + + + See also pcntl_waitpid and + pcntl_wexitstatus. + + + + + + + + pcntl_wifsignaled + + Returns &true; if status code represents a termination due to a + signal + + + + Description + + + int pcntl_wifsignaled + int status + + + + Returns &true; if the child process exited because of a signal + which was not caught. + + + The parameter status is the status + parameter supplied to a successfull call to pcntl_waitpid. + + + See also pcntl_waitpid and + pcntl_signal. + + + + + + + + pcntl_wifstopped + + Returns &true; if child process is currently stopped + + + + Description + + + int pcntl_wifstopped + int status + + + + Returns &true; if the child process which caused the return is + currently stopped; this is only possible if the call to + pcntl_waitpid was done using the option + WUNTRACED. + + + The parameter status is the status + parameter supplied to a successfull call to + pcntl_waitpid. + + + See also pcntl_waitpid. + + + + + + + + pcntl_wstopsig + + Returns the signal which caused the child to stop + + + + Description + + + int pcntl_wstopsig + int status + + + + Returns the number of the signal which caused the child to stop. + This function is only useful if + pcntl_wifstopped returned &true;. + + + The parameter status is the status + parameter supplied to a successfull call to + pcntl_waitpid. + + + See also pcntl_waitpid and + pcntl_wifstopped. + + + + + + + + pcntl_wtermsig + + Returns the signal which caused the child to terminate + + + + Description + + + int pcntl_wtermsig + int status + + + + Returns the number of the signal that caused the child process to + terminate. This function is only useful if + pcntl_wifsignaled returned &true;. + + + The parameter status is the status + parameter supplied to a successfull call to + pcntl_waitpid. + + + See also pcntl_waitpid, + pcntl_signal and + pcntl_wifsignaled.