This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: PATCH: PR bfd/14207: linker can produce a NULL GNU_RELRO segment
On Mon, Jun 11, 2012 at 08:53:56PM -0700, H.J. Lu wrote:
> On Mon, Jun 11, 2012 at 6:54 PM, Alan Modra <amodra@gmail.com> wrote:
> > On Mon, Jun 11, 2012 at 10:26:39AM -0700, H.J. Lu wrote:
> >> The real bug is in _bfd_elf_map_sections_to_segments. ?It
> >
> > Agreed.
> >
> >> ? ? ? * elf.c (_bfd_elf_map_sections_to_segments): Properly compute
> >> ? ? ? file size for PT_GNU_RELRO segment.
> >
> > While I think this part of your patch is correct, it is doing quite a
> > lot of unnecessary work. ?How about this instead?
>
> It works. Thanks.
Committed with this changelog. Please commit the other parts of your
patch.
PR ld/14207
* elf.c (_bfd_elf_map_sections_to_segments): Disregard bss type
sections at end of PT_LOAD segment when searching for segment
that contains end of relro extent.
--
Alan Modra
Australia Development Lab, IBM