diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2015-01-18 16:17:27 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2015-01-18 16:17:27 +0000 |
commit | 67c32a98315f785a9ec9d531c1f571a0196c7463 (patch) | |
tree | 4abb9cbeecc7901726dd0b4a37369596c852e9ef /lib/Support/Timer.cpp | |
parent | 9f61947910e6ab40de38e6b4034751ef1513200f (diff) |
Diffstat (limited to 'lib/Support/Timer.cpp')
-rw-r--r-- | lib/Support/Timer.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Support/Timer.cpp b/lib/Support/Timer.cpp index 210bda754e74..e1a531a0af25 100644 --- a/lib/Support/Timer.cpp +++ b/lib/Support/Timer.cpp @@ -66,10 +66,10 @@ raw_ostream *llvm::CreateInfoOutputFile() { // each time -stats or -time-passes wants to print output to it. To // compensate for this, the test-suite Makefiles have code to delete the // info output file before running commands which write to it. - std::string Error; - raw_ostream *Result = new raw_fd_ostream( - OutputFilename.c_str(), Error, sys::fs::F_Append | sys::fs::F_Text); - if (Error.empty()) + std::error_code EC; + raw_ostream *Result = new raw_fd_ostream(OutputFilename, EC, + sys::fs::F_Append | sys::fs::F_Text); + if (!EC) return Result; errs() << "Error opening info-output-file '" |