1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 03:33:20 +01:00

Section indices in MachO symbol tables begin at 1, not 0.

llvm-svn: 141815
This commit is contained in:
Owen Anderson 2011-10-12 21:43:24 +00:00
parent 974c799a5a
commit 43ef26d840

View File

@ -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;