MCPcopy Create free account
hub / github.com/corosync/corosync / sam_parent_kill_child

Function sam_parent_kill_child

lib/sam.c:1005–1028  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1003}
1004
1005static cs_error_t sam_parent_kill_child (
1006 int *action,
1007 pid_t child_pid)
1008{
1009 /*
1010 * Kill child process
1011 */
1012 if (!sam_internal_data.term_send) {
1013 /*
1014 * We didn't send warn_signal yet.
1015 */
1016 kill (child_pid, sam_internal_data.warn_signal);
1017
1018 sam_internal_data.term_send = 1;
1019 } else {
1020 /*
1021 * We sent child warning. Now, we will not be so nice
1022 */
1023 kill (child_pid, SIGKILL);
1024 *action = SAM_PARENT_ACTION_RECOVERY;
1025 }
1026
1027 return (CS_OK);
1028}
1029
1030static cs_error_t sam_parent_mark_child_failed (
1031 int *action,

Callers 2

sam_parent_handlerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected