We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 5cd4517 + 83aa89a commit d2e81f0Copy full SHA for d2e81f0
src/patchelf.cc
@@ -778,7 +778,7 @@ void ElfFile<ElfFileParamNames>::rewriteSectionsLibrary()
778
/* Some sections may already be replaced so account for that */
779
unsigned int i = 1;
780
Elf_Addr pht_size = sizeof(Elf_Ehdr) + (phdrs.size() + num_notes + 1)*sizeof(Elf_Phdr);
781
- while( shdrs[i].sh_addr <= pht_size && i < rdi(hdr->e_shnum) ) {
+ while( shdrs[i].sh_offset <= pht_size && i < rdi(hdr->e_shnum) ) {
782
if (not haveReplacedSection(getSectionName(shdrs[i])))
783
replaceSection(getSectionName(shdrs[i]), shdrs[i].sh_size);
784
i++;
0 commit comments