mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-12-14 19:49:36 +00:00
Simplify. NFC.
Using getOffset is here was a bit of an overkill. This is being written and has relocations. This implies it is a .eh_frame or regular section. llvm-svn: 330307
This commit is contained in:
parent
719fcd08c6
commit
9c680301b0
@ -710,7 +710,9 @@ void InputSectionBase::relocateAlloc(uint8_t *Buf, uint8_t *BufEnd) {
|
||||
const unsigned Bits = Config->Wordsize * 8;
|
||||
|
||||
for (const Relocation &Rel : Relocations) {
|
||||
uint64_t Offset = getOffset(Rel.Offset);
|
||||
uint64_t Offset = Rel.Offset;
|
||||
if (auto *Sec = dyn_cast<InputSection>(this))
|
||||
Offset += Sec->OutSecOff;
|
||||
uint8_t *BufLoc = Buf + Offset;
|
||||
RelType Type = Rel.Type;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user