Remove useless local variable.

llvm-svn: 300294
This commit is contained in:
Rui Ueyama 2017-04-14 01:35:04 +00:00
parent c49bdd6d5d
commit 0faa53aaab
1 changed files with 2 additions and 4 deletions

View File

@ -661,11 +661,9 @@ template <class ELFT> void InputSection::writeTo(uint8_t *Buf) {
return;
}
// Copy section contents from source object file to output file.
ArrayRef<uint8_t> Data = this->Data;
// Copy section contents from source object file to output file
// and then apply relocations.
memcpy(Buf + OutSecOff, Data.data(), Data.size());
// Iterate over all relocation sections that apply to this section.
uint8_t *BufEnd = Buf + OutSecOff + Data.size();
this->relocate<ELFT>(Buf, BufEnd);
}