https://sourceware.org/bugzilla/show_bug.cgi?id=20401
--- Comment #2 from Ozkan Sezer <sezeroz at gmail dot com> ---
(In reply to Nick Clifton from comment #1)
> Hi Ozkan,
>
> > We ran into a segfault with the djgpp port of ld in fini_reloc_cookie_rels()
>
> Would it be possible for you to upload a small testcase that reproduces this
> problem ?
>
Well, that's super easy:
$ cat test.c
int main () { return 0; }
$ i586-pc-msdosdjgpp-gcc -Wl,--gc-sections test.c
collect2: ld terminated with signal 11 [Segmentation fault]
> > - if (cookie->rels && coff_section_data (NULL, sec)->relocs !=
> > cookie->rels)
> > + if (cookie->rels && (!coff_section_data (NULL, sec) || coff_section_data
> > (NULL, sec)->relocs != cookie->rels))
>
> This is certainly a reasonable first step, but we ought to find out why the
> coff_section_data is NULL. Probably the linker garbage collection has
> deleted the section, but it would be nice to confirm this.
>
Yes, as I said mine is just a workaround the seg. I don't know how I
can find the root cause of it. If you want me to run tests, I can do
so.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
bug-binutils mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-binutils