about summary refs log tree commit diff homepage
path: root/lib/Support/CompressionStream.cpp
diff options
context:
space:
mode:
authorAndrea Mattavelli <andreamattavelli@users.noreply.github.com>2017-07-24 16:17:04 +0200
committerGitHub <noreply@github.com>2017-07-24 16:17:04 +0200
commit769bd87658d3445af6770cadb1fe50edea833d15 (patch)
tree685a818fd4a7336232168fde9b86eb229b23e730 /lib/Support/CompressionStream.cpp
parent9fb2f5666d5f8c7c2f335fc8408883a0cf958964 (diff)
parent72ea2c66dd4da5971914dce334138f2d5f8db19a (diff)
downloadklee-769bd87658d3445af6770cadb1fe50edea833d15.tar.gz
Merge pull request #713 from MartinNowack/remove_llvm_29_33
Remove support for LLVM < 3.4
Diffstat (limited to 'lib/Support/CompressionStream.cpp')
-rw-r--r--lib/Support/CompressionStream.cpp13
1 files changed, 2 insertions, 11 deletions
diff --git a/lib/Support/CompressionStream.cpp b/lib/Support/CompressionStream.cpp
index 36303878..3cd5bc86 100644
--- a/lib/Support/CompressionStream.cpp
+++ b/lib/Support/CompressionStream.cpp
@@ -10,8 +10,7 @@
 #include "klee/Config/Version.h"
 #ifdef HAVE_ZLIB_H
 #include "klee/Internal/Support/CompressionStream.h"
-#if (LLVM_VERSION_CODE >= LLVM_VERSION(3, 3) \
-    && LLVM_VERSION_CODE <= LLVM_VERSION(3, 4))
+#if (LLVM_VERSION_CODE == LLVM_VERSION(3, 4))
 #include "llvm/Support/system_error.h"
 #else
 #include "llvm/Support/FileSystem.h"
@@ -27,12 +26,11 @@ compressed_fd_ostream::compressed_fd_ostream(const char *Filename,
                                              std::string &ErrorInfo)
     : llvm::raw_ostream(), pos(0) {
   ErrorInfo = "";
-#if LLVM_VERSION_CODE >= LLVM_VERSION(3, 3)
   // Open file in binary mode
 #if LLVM_VERSION_CODE >= LLVM_VERSION(3, 5)
   std::error_code EC =
       llvm::sys::fs::openFileForWrite(Filename, FD, llvm::sys::fs::F_None);
-#elif LLVM_VERSION_CODE >= LLVM_VERSION(3, 3)
+#else
   llvm::error_code EC =
       llvm::sys::fs::openFileForWrite(Filename, FD, llvm::sys::fs::F_Binary);
 #endif
@@ -40,13 +38,6 @@ compressed_fd_ostream::compressed_fd_ostream(const char *Filename,
     ErrorInfo = EC.message();
     FD = -1;
   }
-#else
-  FD = ::open(Filename, O_WRONLY | O_CREAT | O_TRUNC, 0666);
-  if (FD < 0) {
-    ErrorInfo = "Could not open file.";
-    FD = -1;
-  }
-#endif
   // Initialize the compression library
   strm.zalloc = 0;
   strm.zfree = 0;