diff options
author | Owen Anderson <resistor@mac.com> | 2011-10-12 21:43:24 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2011-10-12 21:43:24 +0000 |
commit | f903c154c7cc15484b042e602cbdfa54e06fbac7 (patch) | |
tree | baf64e7866f7b4f4611ef94be7764f61a393bf9d /llvm/lib/Object/MachOObjectFile.cpp | |
parent | e7c0c499b89fc092a3de0f102e22f5a16325eb04 (diff) | |
download | bcm5719-llvm-f903c154c7cc15484b042e602cbdfa54e06fbac7.tar.gz bcm5719-llvm-f903c154c7cc15484b042e602cbdfa54e06fbac7.zip |
Section indices in MachO symbol tables begin at 1, not 0.
llvm-svn: 141815
Diffstat (limited to 'llvm/lib/Object/MachOObjectFile.cpp')
-rw-r--r-- | llvm/lib/Object/MachOObjectFile.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Object/MachOObjectFile.cpp b/llvm/lib/Object/MachOObjectFile.cpp index b89ff4beb7a..21fd4b6915c 100644 --- a/llvm/lib/Object/MachOObjectFile.cpp +++ b/llvm/lib/Object/MachOObjectFile.cpp @@ -153,7 +153,7 @@ error_code MachOObjectFile::getSymbolAddress(DataRefImpl DRI, SymbolOffset = Entry->Value; SectionIndex = Entry->SectionIndex; } - getSectionAddress(Sections[SectionIndex], Result); + getSectionAddress(Sections[SectionIndex-1], Result); Result += SymbolOffset; return object_error::success; |