summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Object
diff options
context:
space:
mode:
authorJoseph Tremoulet <jotrem@microsoft.com>2019-04-04 14:13:28 +0000
committerJoseph Tremoulet <jotrem@microsoft.com>2019-04-04 14:13:28 +0000
commit9f598ac7062cfb72d17d59a8f2ab322d2d31a60d (patch)
tree01982f12cfdbc733a86ad55754a64c3fa0effede /llvm/lib/Object
parentb28b4c903685e2e4537ba48fc5b818f028def1d9 (diff)
downloadbcm5719-llvm-9f598ac7062cfb72d17d59a8f2ab322d2d31a60d.tar.gz
bcm5719-llvm-9f598ac7062cfb72d17d59a8f2ab322d2d31a60d.zip
[COFF] Fix delay import directory iterator
Summary: Take the Index into account in `getDelayImportTable`, otherwise we always return the entry for the first delay DLL reference. Reviewers: ruiu Reviewed By: ruiu Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D60081 llvm-svn: 357697
Diffstat (limited to 'llvm/lib/Object')
-rw-r--r--llvm/lib/Object/COFFObjectFile.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Object/COFFObjectFile.cpp b/llvm/lib/Object/COFFObjectFile.cpp
index 7839c65516b..d52206d8cd3 100644
--- a/llvm/lib/Object/COFFObjectFile.cpp
+++ b/llvm/lib/Object/COFFObjectFile.cpp
@@ -1457,7 +1457,7 @@ std::error_code DelayImportDirectoryEntryRef::getName(StringRef &Result) const {
std::error_code DelayImportDirectoryEntryRef::
getDelayImportTable(const delay_import_directory_table_entry *&Result) const {
- Result = Table;
+ Result = &Table[Index];
return std::error_code();
}
OpenPOWER on IntegriCloud