diff options
author | Benjamin Kramer <benny.kra@googlemail.com> | 2013-10-03 16:59:14 +0000 |
---|---|---|
committer | Benjamin Kramer <benny.kra@googlemail.com> | 2013-10-03 16:59:14 +0000 |
commit | 63fac20ec524fdbcc59e94c0950be15ee660b3be (patch) | |
tree | 10e6bf4346596a828572cfda3cda64e09493b95f /lib/Support | |
parent | b70a05a871a9ce44231a5f6308271f333c4ad110 (diff) | |
download | external_llvm-63fac20ec524fdbcc59e94c0950be15ee660b3be.zip external_llvm-63fac20ec524fdbcc59e94c0950be15ee660b3be.tar.gz external_llvm-63fac20ec524fdbcc59e94c0950be15ee660b3be.tar.bz2 |
raw_fd_ostream: Be more verbose about the reason when opening a file fails.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191911 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Support')
-rw-r--r-- | lib/Support/raw_ostream.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Support/raw_ostream.cpp b/lib/Support/raw_ostream.cpp index 92fa8b5..cb96489 100644 --- a/lib/Support/raw_ostream.cpp +++ b/lib/Support/raw_ostream.cpp @@ -447,7 +447,8 @@ raw_fd_ostream::raw_fd_ostream(const char *Filename, std::string &ErrorInfo, error_code EC = sys::fs::openFileForWrite(Filename, FD, Flags); if (EC) { - ErrorInfo = "Error opening output file '" + std::string(Filename) + "'"; + ErrorInfo = "Error opening output file '" + std::string(Filename) + "': " + + EC.message(); ShouldClose = false; return; } |