mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-30 16:51:41 +00:00
Fix a bug which incorrectly caused files to be labeled as having
text relocations in certain situations.
This commit is contained in:
parent
4f24af7764
commit
ff0c247c3c
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=33970
@ -960,14 +960,16 @@ elf_i386_size_dynamic_sections (output_bfd, info)
|
||||
relocs = true;
|
||||
|
||||
/* If this relocation section applies to a read only
|
||||
section, then we probably need a DT_TEXTREL
|
||||
entry. The entries in the .rel.plt section
|
||||
really apply to the .got section, which we
|
||||
created ourselves and so know is not readonly. */
|
||||
section which is in memory at run time, then
|
||||
we probably need a DT_TEXTREL entry. The entries
|
||||
in the .rel.plt section really apply to the
|
||||
.got section, which we created ourselves and so
|
||||
know is not readonly. */
|
||||
outname = bfd_get_section_name (output_bfd,
|
||||
s->output_section);
|
||||
target = bfd_get_section_by_name (output_bfd, outname + 4);
|
||||
if (target != NULL
|
||||
&& (target->flags & SEC_ALLOC) != 0
|
||||
&& (target->flags & SEC_READONLY) != 0)
|
||||
reltext = true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user