Lines Matching refs:si
1626 static void invoke_sigchld_event(Manager *m, Unit *u, const siginfo_t *si) {
1629 assert(si);
1631 log_unit_debug(u, "Child "PID_FMT" belongs to %s", si->si_pid, u->id);
1633 unit_unwatch_pid(u, si->si_pid);
1634 UNIT_VTABLE(u)->sigchld_event(u, si->si_pid, si->si_code, si->si_status);
1641 siginfo_t si = {};
1646 if (waitid(P_ALL, 0, &si, WEXITED|WNOHANG|WNOWAIT) < 0) {
1657 if (si.si_pid <= 0)
1660 if (si.si_code == CLD_EXITED || si.si_code == CLD_KILLED || si.si_code == CLD_DUMPED) {
1664 get_process_comm(si.si_pid, &name);
1667 si.si_pid, strna(name),
1668 sigchld_code_to_string(si.si_code),
1669 si.si_status,
1670 strna(si.si_code == CLD_EXITED
1671 ? exit_status_to_string(si.si_status, EXIT_STATUS_FULL)
1672 : signal_to_string(si.si_status)));
1676 u1 = manager_get_unit_by_pid_cgroup(m, si.si_pid);
1678 invoke_sigchld_event(m, u1, &si);
1679 u2 = hashmap_get(m->watch_pids1, PID_TO_PTR(si.si_pid));
1681 invoke_sigchld_event(m, u2, &si);
1682 u3 = hashmap_get(m->watch_pids2, PID_TO_PTR(si.si_pid));
1684 invoke_sigchld_event(m, u3, &si);
1688 if (waitid(P_PID, si.si_pid, &si, WEXITED) < 0) {