.\" $Id: mbkwaitpid.3,v 1.1.1.1 2002/03/08 13:51:03 fred Exp $ .\" @(#)mbkalloc.2 2.11 91/08/22 ; Labo masi cao-vlsi; Author : Frederic Petrot .if t \{\ .XS \n% .ti 0.2i mbkalloc .XE .XS4 \n% .ti 0.2i mbkalloc .XE4 \} .TH MBKWAITPID 3 "November 20, 2000" "ASIM/LIP6" "MBK UTILITY FUNCTIONS" .SH NAME mbkwaitpid \- wait for the end of a particular child process. .so jessie/alliance/alc_origin.1.en.gz .SH SYNOPSYS .nf .if n \{\ .ft B \} .if t \{\ .ft CR \} #include "mut.h" int mbkwaitpid( pid, mode, status ) int pid; int mode; int \(**status; .ft R .fi .SH PARAMETER .TP 20 \fIpid\fP Process number to wait. .TP \fImode\fP If mode is set to 1, this function return only when the child process is terminated. Otherwise, function return immediatly. .TP \fIstatus\fP If not NULL, the exit status of terminated child process. .SH DESCRIPTION \fBmbkwaitpid\fP provides a centralized way to catch terminated child process. Because some Alliance library can create a child process, and user application can do so, there must be a centralized way to get the exit status of process. The programmer should never modify the handler for SIGCHLD. .SH RETURN VALUE \fBmbkwaitpid\fP return 1 if child process is terminated, and 0 if isn't (case mode != 1 ). .SH SEE ALSO .BR mbk (1), .BR mbksetautoackchld(). .so jessie/alliance/alc_bug_report.1.en.gz