summaryrefslogtreecommitdiffstats
path: root/compiler/elf_writer.cc
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/elf_writer.cc')
-rw-r--r--compiler/elf_writer.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/compiler/elf_writer.cc b/compiler/elf_writer.cc
index d3c13dd..0bfe4a4 100644
--- a/compiler/elf_writer.cc
+++ b/compiler/elf_writer.cc
@@ -47,8 +47,9 @@ llvm::ELF::Elf32_Addr ElfWriter::GetOatDataAddress(ElfFile* elf_file) {
void ElfWriter::GetOatElfInformation(File* file,
size_t& oat_loaded_size,
size_t& oat_data_offset) {
- UniquePtr<ElfFile> elf_file(ElfFile::Open(file, false, false));
- CHECK(elf_file.get() != NULL);
+ std::string error_msg;
+ UniquePtr<ElfFile> elf_file(ElfFile::Open(file, false, false, &error_msg));
+ CHECK(elf_file.get() != NULL) << error_msg;
oat_loaded_size = elf_file->GetLoadedSize();
CHECK_NE(0U, oat_loaded_size);