private function afterChildDeathWithStatus($status, $attempts, $lastWill)
{
$lastWill->play();
if ($status !== 0) {
if ($this->canTryAnotherTime($status, $attempts, $lastWill)) {
return [true, null];
}
return [false, call_user_func($this->afterViolentDeath, $status, $lastWill->whatDidHeSayOnStdout(), $lastWill->whatDidHeSayOnStderr())];
}
return [false, call_user_func($this->afterNaturalDeath, $status, $lastWill->whatDidHeSayOnStdout())];
}