forked from OSchip/llvm-project
[ELF] Simplify InputSection::writeTo. NFC
This commit is contained in:
parent
ad39b5bc59
commit
14b7785c09
|
@ -1261,9 +1261,8 @@ template <class ELFT> void InputSection::writeTo(uint8_t *buf) {
|
|||
|
||||
// Copy section contents from source object file to output file
|
||||
// and then apply relocations.
|
||||
memcpy(buf, data().data(), data().size());
|
||||
uint8_t *bufEnd = buf + data().size();
|
||||
relocate<ELFT>(buf, bufEnd);
|
||||
memcpy(buf, rawData.data(), rawData.size());
|
||||
relocate<ELFT>(buf, buf + rawData.size());
|
||||
}
|
||||
|
||||
void InputSection::replace(InputSection *other) {
|
||||
|
|
Loading…
Reference in New Issue