Merge pull request #117363 from bruvzg/oipr_msg
Improve `OS.is_process_running` error messages.
This commit is contained in:
commit
ce66ff689e
1 changed files with 2 additions and 2 deletions
|
|
@ -857,8 +857,8 @@ bool OS_Unix::_check_pid_is_running(const pid_t p_pid, int *r_status) const {
|
|||
// Thread is still running.
|
||||
return true;
|
||||
}
|
||||
|
||||
ERR_FAIL_COND_V_MSG(result != 0, false, vformat("Thread %d exited with errno: %d", (int)p_pid, errno));
|
||||
ERR_FAIL_COND_V_MSG(result != 0 && errno == ECHILD, false, vformat("The process %d does not exist or is not a child of the calling process.", (int)p_pid));
|
||||
ERR_FAIL_COND_V_MSG(result != 0, false, vformat("waitpid for process %d failed with errno: %d", (int)p_pid, errno));
|
||||
|
||||
// Thread exited normally.
|
||||
status = WIFEXITED(status) ? WEXITSTATUS(status) : status;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue