coff patch for ld -r -S crash with djgpp

Mark E. snowball3@softhome.net
Tue Sep 24 11:45:00 GMT 2002


Hi guys,
This fixes a crash when using djgpp's dxe module generator with dwarf2 info.

bfd/Changelog:

2002-09-24  Mark Elbrecht  <snowball3@softhome.net>

	* cofflink.c (mark_relocs): Don't mark relocations in excluded sections.

Index: cofflink.c
===================================================================
RCS file: /cvs/src/src/bfd/cofflink.c,v
retrieving revision 1.34
diff -c -p -r1.34 cofflink.c
*** cofflink.c	8 Jul 2002 05:34:07 -0000	1.34
--- cofflink.c	24 Sep 2002 16:49:54 -0000
*************** mark_relocs (finfo, input_bfd)
*** 1322,1327 ****
--- 1322,1330 ----
  
        if ((a->flags & SEC_RELOC) == 0 || a->reloc_count  < 1)
  	continue;
+       /* Don't mark relocs in excluded sections.  */
+       if (a->output_section == bfd_abs_section_ptr)
+ 	continue;
  
        /* Read in the relocs.  */
        internal_relocs = _bfd_coff_read_internal_relocs



More information about the Binutils mailing list