Lines Matching refs:pid
27 pid_t pid;
33 pid = vfork();
34 if (pid < 0) /* error */
35 return pid;
36 if (!pid) { /* child */
51 * Interested party can wait on pid and learn exit code.
57 return pid;
63 pid_t pid = spawn(argv);
64 if (pid < 0)
66 return pid;
70 int wait4pid(int pid)
74 if (pid <= 0) {
79 if (waitpid(pid, &status, 0) == -1)
93 int wait_pid(int *wstat, int pid)
98 r = waitpid(pid, wstat, 0);
217 pid_t pid;
222 pid = vfork();
223 if (pid < 0) /* wtf? */
225 if (pid) /* parent */
235 pid_t pid;
236 pid = fork();
237 if (pid < 0) /* wtf? */
239 if (pid) /* parent */