summaryrefslogtreecommitdiff
path: root/tools/llvm-stress/llvm-stress.cpp
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2015-01-18 16:17:27 +0000
committerDimitry Andric <dim@FreeBSD.org>2015-01-18 16:17:27 +0000
commit67c32a98315f785a9ec9d531c1f571a0196c7463 (patch)
tree4abb9cbeecc7901726dd0b4a37369596c852e9ef /tools/llvm-stress/llvm-stress.cpp
parent9f61947910e6ab40de38e6b4034751ef1513200f (diff)
Diffstat (limited to 'tools/llvm-stress/llvm-stress.cpp')
-rw-r--r--tools/llvm-stress/llvm-stress.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/tools/llvm-stress/llvm-stress.cpp b/tools/llvm-stress/llvm-stress.cpp
index 23d3b636b190d..21a79e3294a04 100644
--- a/tools/llvm-stress/llvm-stress.cpp
+++ b/tools/llvm-stress/llvm-stress.cpp
@@ -704,11 +704,10 @@ int main(int argc, char **argv) {
if (OutputFilename.empty())
OutputFilename = "-";
- std::string ErrorInfo;
- Out.reset(new tool_output_file(OutputFilename.c_str(), ErrorInfo,
- sys::fs::F_None));
- if (!ErrorInfo.empty()) {
- errs() << ErrorInfo << '\n';
+ std::error_code EC;
+ Out.reset(new tool_output_file(OutputFilename, EC, sys::fs::F_None));
+ if (EC) {
+ errs() << EC.message() << '\n';
return 1;
}