forked from OSchip/llvm-project
[ELF] - Read 16 bits for R_386_16/R_386_PC16 relocations instead of 32.
Looks it was theoretically incorrect if the section is at the very end of the file as reading 32 bits would pass the end of file llvm-svn: 289046
This commit is contained in:
parent
baffdb8bc2
commit
c49fd8c477
|
@ -439,12 +439,13 @@ uint64_t X86TargetInfo::getImplicitAddend(const uint8_t *Buf,
|
|||
default:
|
||||
return 0;
|
||||
case R_386_16:
|
||||
case R_386_PC16:
|
||||
return read16le(Buf);
|
||||
case R_386_32:
|
||||
case R_386_GOT32:
|
||||
case R_386_GOT32X:
|
||||
case R_386_GOTOFF:
|
||||
case R_386_GOTPC:
|
||||
case R_386_PC16:
|
||||
case R_386_PC32:
|
||||
case R_386_PLT32:
|
||||
case R_386_TLS_LE:
|
||||
|
|
Loading…
Reference in New Issue