summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Object/Binary.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2014-01-29 00:02:26 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2014-01-29 00:02:26 +0000
commitc3ceeb6fa751e82de1aff19ff0cf812fc94237cb (patch)
treeae2c82fe314eda2be055d940c1a5dca99182b9ab /llvm/lib/Object/Binary.cpp
parent1e632af0d4989357836a52ff8a0e237e69ca81d3 (diff)
downloadbcm5719-llvm-c3ceeb6fa751e82de1aff19ff0cf812fc94237cb.tar.gz
bcm5719-llvm-c3ceeb6fa751e82de1aff19ff0cf812fc94237cb.zip
Make createObjectFile's signature a bit less error prone.
This will be better with c++11, but right now file_magic converts to bool, which makes the api really easy to misuse. llvm-svn: 200357
Diffstat (limited to 'llvm/lib/Object/Binary.cpp')
-rw-r--r--llvm/lib/Object/Binary.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Object/Binary.cpp b/llvm/lib/Object/Binary.cpp
index a2f4ec9a0b8..63898d277f3 100644
--- a/llvm/lib/Object/Binary.cpp
+++ b/llvm/lib/Object/Binary.cpp
@@ -67,7 +67,7 @@ ErrorOr<Binary *> object::createBinary(MemoryBuffer *Source,
case sys::fs::file_magic::coff_object:
case sys::fs::file_magic::coff_import_library:
case sys::fs::file_magic::pecoff_executable:
- return ObjectFile::createObjectFile(scopedSource.take(), Type);
+ return ObjectFile::createObjectFile(scopedSource.take(), true, Type);
case sys::fs::file_magic::macho_universal_binary:
return MachOUniversalBinary::create(scopedSource.take());
case sys::fs::file_magic::unknown:
OpenPOWER on IntegriCloud