diff options
Diffstat (limited to 'libdexfile/external/dex_file_ext.cc')
-rw-r--r-- | libdexfile/external/dex_file_ext.cc | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/libdexfile/external/dex_file_ext.cc b/libdexfile/external/dex_file_ext.cc index 5a6dc219cb..3a511ea1c9 100644 --- a/libdexfile/external/dex_file_ext.cc +++ b/libdexfile/external/dex_file_ext.cc @@ -192,11 +192,12 @@ ADexFile_Error ADexFile_create(const void* _Nonnull address, std::string loc_str(location); std::string error_msg; art::DexFileLoader loader(static_cast<const uint8_t*>(address), full_size, loc_str); - std::unique_ptr<const art::DexFile> dex_file = loader.Open(header->checksum_, - /*oat_dex_file=*/nullptr, - /*verify=*/false, - /*verify_checksum=*/false, - &error_msg); + std::unique_ptr<const art::DexFile> dex_file = loader.OpenOne(/*header_offset=*/0, + header->checksum_, + /*oat_dex_file=*/nullptr, + /*verify=*/false, + /*verify_checksum=*/false, + &error_msg); if (dex_file == nullptr) { LOG(ERROR) << "Can not open dex file " << loc_str << ": " << error_msg; return ADEXFILE_ERROR_INVALID_DEX; |