aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/Support/ToolRunner.cpp9
-rw-r--r--tools/bugpoint/ToolRunner.cpp9
2 files changed, 8 insertions, 10 deletions
diff --git a/lib/Support/ToolRunner.cpp b/lib/Support/ToolRunner.cpp
index 4538bb2..2fa5b39 100644
--- a/lib/Support/ToolRunner.cpp
+++ b/lib/Support/ToolRunner.cpp
@@ -306,8 +306,7 @@ int GCC::ExecuteProgram(const std::string &ProgramFile,
return ProgramResult;
}
-int GCC::MakeSharedObject(const std::string &InputFile,
- FileType fileType,
+int GCC::MakeSharedObject(const std::string &InputFile, FileType fileType,
std::string &OutputFile) {
OutputFile = getUniqueFilename(InputFile+".so");
// Compile the C/asm file into a shared object
@@ -327,10 +326,10 @@ int GCC::MakeSharedObject(const std::string &InputFile,
};
std::cout << "<gcc>" << std::flush;
- if(RunProgramWithTimeout(GCCPath, GCCArgs, "/dev/null", "/dev/null",
- "/dev/null")) {
+ if (RunProgramWithTimeout(GCCPath, GCCArgs, "/dev/null", "/dev/null",
+ "/dev/null")) {
ProcessFailure(GCCArgs);
- exit(1);
+ return 1;
}
return 0;
}
diff --git a/tools/bugpoint/ToolRunner.cpp b/tools/bugpoint/ToolRunner.cpp
index 4538bb2..2fa5b39 100644
--- a/tools/bugpoint/ToolRunner.cpp
+++ b/tools/bugpoint/ToolRunner.cpp
@@ -306,8 +306,7 @@ int GCC::ExecuteProgram(const std::string &ProgramFile,
return ProgramResult;
}
-int GCC::MakeSharedObject(const std::string &InputFile,
- FileType fileType,
+int GCC::MakeSharedObject(const std::string &InputFile, FileType fileType,
std::string &OutputFile) {
OutputFile = getUniqueFilename(InputFile+".so");
// Compile the C/asm file into a shared object
@@ -327,10 +326,10 @@ int GCC::MakeSharedObject(const std::string &InputFile,
};
std::cout << "<gcc>" << std::flush;
- if(RunProgramWithTimeout(GCCPath, GCCArgs, "/dev/null", "/dev/null",
- "/dev/null")) {
+ if (RunProgramWithTimeout(GCCPath, GCCArgs, "/dev/null", "/dev/null",
+ "/dev/null")) {
ProcessFailure(GCCArgs);
- exit(1);
+ return 1;
}
return 0;
}