[LLD][ELF] - Eliminate dead code from OffsetGetter::get().
authorGeorge Rimar <grimar@accesssoftek.com>
Tue, 14 Aug 2018 14:20:34 +0000 (14:20 +0000)
committerGeorge Rimar <grimar@accesssoftek.com>
Tue, 14 Aug 2018 14:20:34 +0000 (14:20 +0000)
commit48ca274d2fcf1bfecdf9a601ad8049889d2302fe
treee4c6428ddee3ce1614f398b78cd881a5232a325e
parentdf9880f2572a8ff93c393ab322b15f6061cfcbfc
[LLD][ELF] - Eliminate dead code from OffsetGetter::get().

We have a dead piece of code there which is impossible to trigger
using regular objects I believe.
Patch removes it and adds a test case showing how this condition
can be triggered with use of a broken object and crash the linker.

llvm-svn: 339680
lld/ELF/Relocations.cpp
lld/test/ELF/invalid/ehframe-broken-relocation.test [new file with mode: 0644]