This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
[patch] elf32-mips.c: Handle unrecognized relocs a bit better
- To: binutils at sourceware dot cygnus dot com
- Subject: [patch] elf32-mips.c: Handle unrecognized relocs a bit better
- From: Diego Novillo <dnovillo at redhat dot com>
- Date: Wed, 21 Mar 2001 16:04:02 -0500
- Organization: Red Hat Canada
This patch changes an abort() into a more descriptive error
message when a relocation is not recognized.
OK to install?
2001-03-07 Diego Novillo <dnovillo@redhat.com>
(_bfd_mips_elf_relocate_section): Give a better error message when
a relocation is not recognized.
Index: elf32-mips.c
===================================================================
RCS file: /cvs/src/src/bfd/elf32-mips.c,v
retrieving revision 1.89
diff -d -c -p -r1.89 elf32-mips.c
*** elf32-mips.c 2001/03/08 21:04:00 1.89
--- elf32-mips.c 2001/03/21 21:01:06
*************** _bfd_mips_elf_relocate_section (output_b
*** 6771,6776 ****
--- 6771,6777 ----
REL relocation. */
boolean rela_relocation_p = true;
int r_type = ELF32_R_TYPE (rel->r_info);
+ const char * msg = (const char *) NULL;
/* Find the relocation howto for this relocation. */
if (r_type == R_MIPS_64 && !ABI_64_P (output_bfd))
*************** _bfd_mips_elf_relocate_section (output_b
*** 7025,7032 ****
continue;
case bfd_reloc_notsupported:
! abort ();
! break;
case bfd_reloc_overflow:
if (use_saved_addend_p)
--- 7026,7035 ----
continue;
case bfd_reloc_notsupported:
! msg = _("internal error: unsupported relocation error");
! info->callbacks->warning
! (info, msg, name, input_bfd, input_section, rel->r_offset);
! return false;
case bfd_reloc_overflow:
if (use_saved_addend_p)