From: Devang Patel Date: Mon, 4 Feb 2008 20:57:54 +0000 (+0000) Subject: Set error message. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=a1e4bba98ad4f23f4385c1178b214a03c0469464;p=oota-llvm.git Set error message. Patch by Shantonu Sen. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46715 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/System/Unix/Program.inc b/lib/System/Unix/Program.inc index 033a8a45947..91baefb3294 100644 --- a/lib/System/Unix/Program.inc +++ b/lib/System/Unix/Program.inc @@ -242,9 +242,11 @@ Program::ExecuteAndWait(const Path& path, // Wait for child to die if (wait(&status) != child) MakeErrMsg(ErrMsg, "Child timed out but wouldn't die"); - + else + MakeErrMsg(ErrMsg, "Child timed out", 0); + return -1; // Timeout detected - } else { + } else if (errno != EINTR) { MakeErrMsg(ErrMsg, "Error waiting for child process"); return -1; }