Path: utzoo!attcan!utgpu!watmath!mks!egisin From: egisin@mks.UUCP (Eric Gisin) Newsgroups: comp.unix.wizards Subject: Re: bug in pclose(3) Summary: waitpid is extendable Message-ID: <633@mks.UUCP> Date: 6 Jan 89 16:39:38 GMT References: <261@ecijmm.UUCP> <14020053@hpisod2.HP.COM> <803@auspex.UUCP> Organization: Mortice Kern Systems, Waterloo, Ont. Lines: 14 In article <803@auspex.UUCP>, guy@auspex.UUCP (Guy Harris) writes: > Since "waitfor()"/"wait4()" does things that "waitpid()" doesn't > (namely, optionally fill in a "struct rusage"), I see no reason why the > people at Berkeley would want to rename "wait{4|for}" to "waitpid". > They may want to provide "waitpid" as a procedure that calls > "wait{4|for}", but that's a different matter. Declare waitpid as pid_t waitpid (pid_t pid, int *statp, int options, ...); #define WRUSAGE 0x10 The option WRUSAGE can indicate that a fourth parameter pointing to a struct rusage exists. There's no need for half-a-dozen wait-like functions in 4.4 BSD.