Home
last modified time | relevance | path

Searched refs:childpid (Results 1 – 10 of 10) sorted by relevance

/external/ltp/testcases/kernel/pty/
Dhangup01.c58 pid_t childpid; variable
65 if (0 < childpid) { in cleanup()
68 if (kill(childpid, 0) == 0 || errno == ESRCH) { in cleanup()
71 (void)kill(childpid, 15); in cleanup()
74 if (waitpid(childpid, &status, WNOHANG) < 0) { in cleanup()
76 "waitpid(%d, ...) failed", childpid); in cleanup()
88 void parent(int masterfd, int childpid) in parent() argument
148 while (waitpid(childpid, &status, WNOHANG) < 0 && errno != ESRCH) ; in parent()
213 pid_t childpid; in main() local
230 childpid = fork(); in main()
[all …]
/external/ltp/testcases/kernel/containers/userns/
Duserns02.c72 int childpid; in main() local
84 childpid = ltp_clone_quick(CLONE_NEWUSER | SIGCHLD, in main()
87 if (childpid < 0) in main()
92 sprintf(path, "/proc/%d/uid_map", childpid); in main()
99 sprintf(path, "/proc/%d/setgroups", childpid); in main()
105 sprintf(path, "/proc/%d/gid_map", childpid); in main()
113 tst_record_childstatus(cleanup, childpid); in main()
/external/valgrind/none/tests/
Dthreaded-fork.c18 pid_t childpid; in main() local
25 childpid = fork(); in main()
26 switch( childpid ) { in main()
41 while(waitpid(childpid, &status, 0) != childpid) { in main()
/external/valgrind/drd/tests/
Dthreaded-fork.c20 pid_t childpid; in main() local
28 childpid = fork(); in main()
29 switch (childpid) { in main()
43 while (waitpid(childpid, &status, 0) != childpid) { in main()
/external/ltp/testcases/kernel/syscalls/ioctl/
Dioctl02.c80 static int parentpid, childpid; variable
132 childpid = FORK_OR_VFORK(); in main()
133 if (childpid < 0) in main()
136 if (childpid == 0) { /* child */ in main()
152 kill(childpid, SIGTERM); in main()
153 waitpid(childpid, NULL, 0); in main()
164 kill(childpid, SIGTERM); in main()
165 waitpid(childpid, NULL, 0); in main()
176 (void)kill(childpid, SIGTERM); in main()
177 (void)waitpid(childpid, NULL, 0); in main()
/external/ltp/testcases/kernel/syscalls/fork/
Dfork06.c55 int i, pid, status, childpid, succeed, fail; in main() local
78 childpid = wait(&status); in main()
79 if (pid != childpid) in main()
80 tst_resm(TFAIL, "pid from wait %d", childpid); in main()
/external/ltp/testcases/kernel/ipc/ipc_stress/
Dsemaphore_test_02.c120 int childpid[MAX_CHILDREN]; variable
166 childpid[proc] = pid; in main()
188 waitpid(childpid[proc], &status, 0); in main()
Dshmem_test_04.c143 int childpid[MAXPROCS]; variable
228 childpid[proc] = pid; in main()
335 kill(childpid[i], SIGKILL); in cleanup()
Dsemaphore_test_03.c136 pid_t childpid[MAX_CHILDREN]; variable
188 childpid[proc] = pid; in main()
210 waitpid(childpid[proc], &status, 0); in main()
/external/selinux/sandbox/
Dseunshare.c141 int childpid; in spawn_command() local
147 childpid = fork(); in spawn_command()
148 if (childpid == -1) { in spawn_command()
153 if (childpid == 0) { in spawn_command()
161 waitpid(childpid, &status, 0); in spawn_command()