about summary refs log tree commit diff homepage
diff options
context:
space:
mode:
authorJiri Slaby <jirislaby@gmail.com>2018-06-15 08:14:39 +0200
committerMartinNowack <martin.nowack@gmail.com>2018-07-12 23:25:49 +0100
commit61bea886da83ba071687f7153e896d5dc6a8ef8c (patch)
tree4cb903464985d4502753860c1ac082e77166229d
parentf7a20a1e0266f79c81e1ccc3b9d5b556748d7657 (diff)
downloadklee-61bea886da83ba071687f7153e896d5dc6a8ef8c.tar.gz
llvm38: SmallString is always up-to-date
No need to flush it, see llvm-mirror/llvm@d4177b2

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
-rw-r--r--tools/klee/main.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/klee/main.cpp b/tools/klee/main.cpp
index b81131d9..c91ce75a 100644
--- a/tools/klee/main.cpp
+++ b/tools/klee/main.cpp
@@ -289,7 +289,12 @@ KleeHandler::KleeHandler(int argc, char **argv)
     for (; i <= INT_MAX; ++i) {
       SmallString<128> d(directory);
       llvm::sys::path::append(d, "klee-out-");
-      raw_svector_ostream ds(d); ds << i; ds.flush();
+      raw_svector_ostream ds(d);
+      ds << i;
+// SmallString is always up-to-date, no need to flush. See Support/raw_ostream.h
+#if LLVM_VERSION_CODE < LLVM_VERSION(3, 8)
+      ds.flush();
+#endif
 
       // create directory and try to link klee-last
       if (mkdir(d.c_str(), 0775) == 0) {