Object: Fix Mach-O relocation printing.
authorAhmed Bougacha <ahmed.bougacha@gmail.com>
Tue, 14 May 2013 22:41:29 +0000 (22:41 +0000)
committerAhmed Bougacha <ahmed.bougacha@gmail.com>
Tue, 14 May 2013 22:41:29 +0000 (22:41 +0000)
commitebb9f17240dd72f3983d2de884d77f03d6eea4c8
tree8661ae0012117a00c0423782c3e96f1b0f56da8a
parent101a36117c2e5e760ebb2b476d6c5b2b52cac6e8
Object: Fix Mach-O relocation printing.

There were two problems that made llvm-objdump -r crash:
- for non-scattered relocations, the symbol/section index is actually in the
  (aptly named) symbolnum field.
- sections are 1-indexed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@181843 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Object/MachOObjectFile.cpp
test/Object/X86/objdump-disassembly-inline-relocations.test