Skip to content

Commit c749f67

Browse files
committed
Use a different letter for section tainting
1 parent 27cbc89 commit c749f67

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/patchelf.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -664,14 +664,14 @@ template<ElfFileParams>
664664
void ElfFile<ElfFileParamNames>::writeReplacedSections(Elf_Off & curOff,
665665
Elf_Addr startAddr, Elf_Off startOffset)
666666
{
667-
/* Overwrite the old section contents with 'X's. Do this
667+
/* Overwrite the old section contents with 'Z's. Do this
668668
*before* writing the new section contents (below) to prevent
669669
clobbering previously written new section contents. */
670670
for (auto & i : replacedSections) {
671671
const std::string & sectionName = i.first;
672672
const Elf_Shdr & shdr = findSectionHeader(sectionName);
673673
if (rdi(shdr.sh_type) != SHT_NOBITS)
674-
memset(fileContents->data() + rdi(shdr.sh_offset), 'X', rdi(shdr.sh_size));
674+
memset(fileContents->data() + rdi(shdr.sh_offset), 'Z', rdi(shdr.sh_size));
675675
}
676676

677677
std::set<unsigned int> noted_phdrs = {};

0 commit comments

Comments
 (0)