summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tools/llvm-dis/llvm-dis.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/tools/llvm-dis/llvm-dis.cpp b/tools/llvm-dis/llvm-dis.cpp
index 7a8bf5afc8..bb91ad6fce 100644
--- a/tools/llvm-dis/llvm-dis.cpp
+++ b/tools/llvm-dis/llvm-dis.cpp
@@ -54,8 +54,9 @@ int main(int argc, char **argv) {
std::string ErrorMessage;
std::auto_ptr<Module> M;
-
- M.reset(ParseBitcodeFile(InputFilename, &ErrorMessage));
+
+ if (InputFilename != "-")
+ M.reset(ParseBitcodeFile(InputFilename, &ErrorMessage));
if (M.get() == 0)
M.reset(ParseBytecodeFile(InputFilename,Compressor::decompressToNewBuffer,