Home
last modified time | relevance | path

Searched refs:child_pid (Results 1 – 8 of 8) sorted by relevance

/system/core/llkd/tests/
Dllkd_test.cpp161 inline void waitForPid(pid_t child_pid) { in waitForPid() argument
163 ASSERT_LE(0, waitpid(child_pid, &wstatus, 0)); in waitForPid()
204 auto child_pid = fork(); in llkd_driver_ABA() local
205 ASSERT_LE(0, child_pid); in llkd_driver_ABA()
207 if (!child_pid) { in llkd_driver_ABA()
229 ASSERT_LE(0, waitpid(child_pid, &wstatus, 0)); in llkd_driver_ABA()
264 pid_t child_pid = fork(); in TEST() local
265 ASSERT_LE(0, child_pid); in TEST()
266 if (!child_pid) { in TEST()
277 waitForPid(child_pid); in TEST()
[all …]
/system/connectivity/wificond/tests/
Dshell_utils.cpp68 const pid_t child_pid = fork(); in RunShellCommand() local
69 if (child_pid == -1) { in RunShellCommand()
73 if (child_pid == 0) { // We are in the child process. in RunShellCommand()
114 auto NeedToWaitForChild = [child_pid, &wait_status, &waitpid_ret]() { in RunShellCommand()
116 waitpid_ret = waitpid(child_pid, &wait_status, WNOHANG); in RunShellCommand()
130 if (waitpid_ret != child_pid) { in RunShellCommand()
131 int kill_ret = kill(child_pid, SIGKILL); in RunShellCommand()
145 if (waitpid_ret == child_pid && WIFEXITED(wait_status)) { in RunShellCommand()
/system/netd/server/
DIptablesRestoreController.cpp155 StatusOr<pid_t> child_pid = sys.fork(); in forkAndExec() local
156 if (!isOk(child_pid)) { in forkAndExec()
157 ALOGE("fork() failed: %s", strerror(child_pid.status().code())); in forkAndExec()
161 if (child_pid.value() == 0) { in forkAndExec()
200 return new IptablesProcess(child_pid.value(), stdin_pipe[1], stdout_pipe[0], stderr_pipe[0]); in forkAndExec()
/system/core/init/
Dservice_utils.cpp99 pid_t child_pid = fork(); in SetUpPidNamespace() local
100 if (child_pid == -1) { in SetUpPidNamespace()
104 if (child_pid > 0) { in SetUpPidNamespace()
115 if (waited_pid == child_pid) { in SetUpPidNamespace()
Dselinux.cpp135 pid_t child_pid = fork(); in ForkExecveAndWaitForCompletion() local
136 if (child_pid == -1) { in ForkExecveAndWaitForCompletion()
141 if (child_pid == 0) { in ForkExecveAndWaitForCompletion()
190 if (TEMP_FAILURE_RETRY(waitpid(child_pid, &status, 0)) != child_pid) { in ForkExecveAndWaitForCompletion()
/system/memory/libmeminfo/libdmabufinfo/
Ddmabufinfo_test.cpp66 bool ok() const { return child_pid > 0; } in ok()
69 pid_t pid() const { return child_pid; } in pid()
73 pid_t child_pid; member in fd_sharer
78 fd_sharer::fd_sharer() : parent_fd{}, child_fd{}, child_pid{-1} { in fd_sharer()
82 child_pid = fork();
83 if (child_pid < 0) return;
85 if (child_pid == 0) run();
89 int err = ::kill(child_pid, SIGKILL); in kill()
92 return ::waitpid(child_pid, nullptr, 0) == child_pid; in kill()
/system/logging/logwrapper/
Dlogwrap.cpp39 static pid_t child_pid; variable
308 child_pid = pid; in setup_signal_handlers()
318 child_pid = 0; in restore_signal_handlers()
322 if (child_pid == 0 || kill(child_pid, signal_num) != 0) { in signal_handler()
/system/core/debuggerd/handler/
Ddebuggerd_handler.cpp574 pid_t child_pid = in debuggerd_signal_handler() local
578 if (child_pid == -1) { in debuggerd_signal_handler()
586 futex_wait(&thread_info.pseudothread_tid, child_pid); in debuggerd_signal_handler()