| Index: base/process_util_posix.cc
|
| ===================================================================
|
| --- base/process_util_posix.cc (revision 80488)
|
| +++ base/process_util_posix.cc (working copy)
|
| @@ -724,14 +724,15 @@
|
| return false;
|
| if (!waitpid_success)
|
| return false;
|
| - if (!WIFEXITED(status))
|
| - return false;
|
| if (WIFSIGNALED(status)) {
|
| *exit_code = -1;
|
| return true;
|
| }
|
| - *exit_code = WEXITSTATUS(status);
|
| - return true;
|
| + if (WIFEXITED(status)) {
|
| + *exit_code = WEXITSTATUS(status);
|
| + return true;
|
| + }
|
| + return false;
|
| }
|
|
|
| #if defined(OS_MACOSX)
|
| @@ -821,19 +822,6 @@
|
| }
|
| }
|
|
|
| -bool CrashAwareSleep(ProcessHandle handle, int64 wait_milliseconds) {
|
| - bool waitpid_success;
|
| - int status = WaitpidWithTimeout(handle, wait_milliseconds, &waitpid_success);
|
| - if (status != -1) {
|
| - DCHECK(waitpid_success);
|
| - return !(WIFEXITED(status) || WIFSIGNALED(status));
|
| - } else {
|
| - // If waitpid returned with an error, then the process doesn't exist
|
| - // (which most probably means it didn't exist before our call).
|
| - return waitpid_success;
|
| - }
|
| -}
|
| -
|
| int64 TimeValToMicroseconds(const struct timeval& tv) {
|
| static const int kMicrosecondsPerSecond = 1000000;
|
| int64 ret = tv.tv_sec; // Avoid (int * int) integer overflow.
|
|
|