summaryrefslogtreecommitdiff
path: root/tools/lli
diff options
context:
space:
mode:
authorLang Hames <lhames@gmail.com>2014-01-09 00:47:54 +0000
committerLang Hames <lhames@gmail.com>2014-01-09 00:47:54 +0000
commitfd4f17f0d9efcad0604ced0f8772ffa3add3fe74 (patch)
tree1089b7fb0820ff1fddf99a810dfd88eb0d83361d /tools/lli
parent0b5675926a3cecfa1f593567d60813924d0f49d6 (diff)
Replace fstream use with raw_fd_ostream.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@198821 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/lli')
-rw-r--r--tools/lli/lli.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/lli/lli.cpp b/tools/lli/lli.cpp
index 102811fec7c..62e232ad68e 100644
--- a/tools/lli/lli.cpp
+++ b/tools/lli/lli.cpp
@@ -53,7 +53,6 @@
#include "llvm/Support/raw_ostream.h"
#include "llvm/Transforms/Instrumentation.h"
#include <cerrno>
-#include <fstream>
#ifdef __CYGWIN__
#include <cygwin/version.h>
@@ -255,7 +254,8 @@ public:
std::string CacheName;
if (!getCacheFilename(ModuleID, CacheName))
return;
- std::ofstream outfile(CacheName.c_str(), std::ofstream::binary);
+ std::string errStr;
+ raw_fd_ostream outfile(CacheName.c_str(), errStr, sys::fs::F_Binary);
outfile.write(Obj->getBufferStart(), Obj->getBufferSize());
outfile.close();
}