[llvm-commits] CVS: llvm/lib/Support/SystemUtils.cpp
Chris Lattner
lattner at cs.uiuc.edu
Sat Jul 24 00:50:58 PDT 2004
Changes in directory llvm/lib/Support:
SystemUtils.cpp updated: 1.31 -> 1.32
---
Log message:
Get rid of the printout from the low-level system interface
---
Diffs of the changes: (+13 -24)
Index: llvm/lib/Support/SystemUtils.cpp
diff -u llvm/lib/Support/SystemUtils.cpp:1.31 llvm/lib/Support/SystemUtils.cpp:1.32
--- llvm/lib/Support/SystemUtils.cpp:1.31 Sat Jul 24 02:41:23 2004
+++ llvm/lib/Support/SystemUtils.cpp Sat Jul 24 02:50:48 2004
@@ -182,34 +182,23 @@
alarm(NumSeconds);
int Status;
- while (wait(&Status) != Child) {
+ while (wait(&Status) != Child)
if (errno == EINTR) {
if (Timeout) {
- static bool FirstTimeout = true;
- if (FirstTimeout) {
- std::cout <<
- "*** Program execution timed out! This mechanism is designed to handle\n"
- " programs stuck in infinite loops gracefully. The -timeout option\n"
- " can be used to change the timeout threshold or disable it completely\n"
- " (with -timeout=0). This message is only displayed once.\n";
- FirstTimeout = false;
- }
+ // Kill the child.
+ kill(Child, SIGKILL);
+
+ if (wait(&Status) != Child)
+ std::cerr << "Something funny happened waiting for the child!\n";
+
+ alarm(0);
+ sigaction(SIGALRM, &Old, 0);
+ return -1; // Timeout detected
+ } else {
+ std::cerr << "Error waiting for child process!\n";
+ exit(1);
}
-
- // Kill the child.
- kill(Child, SIGKILL);
-
- if (wait(&Status) != Child)
- std::cerr << "Something funny happened waiting for the child!\n";
-
- alarm(0);
- sigaction(SIGALRM, &Old, 0);
- return -1; // Timeout detected
- } else {
- std::cerr << "Error waiting for child process!\n";
- exit(1);
}
- }
alarm(0);
sigaction(SIGALRM, &Old, 0);
More information about the llvm-commits
mailing list