ppc32 use of %x in einfo format
authorAlan Modra <amodra@gmail.com>
Tue, 11 Jul 2017 09:48:47 +0000 (19:18 +0930)
committerAlan Modra <amodra@gmail.com>
Tue, 11 Jul 2017 09:48:47 +0000 (19:18 +0930)
einfo doesn't support %x.

* elf32-ppc.c (ppc_elf_relocate_section): Emit "unexpected
instruction" error using _bfd_error_handler, not einfo.

bfd/ChangeLog
bfd/elf32-ppc.c

index 111afcb9a9a04602f7f3ce003ce8ffb49a53e6aa..b60bda14208cb2fe6d47af9ef32f7f3e0fc12d08 100644 (file)
@@ -1,3 +1,8 @@
+2017-07-11  Alan Modra  <amodra@gmail.com>
+
+       * elf32-ppc.c (ppc_elf_relocate_section): Emit "unexpected
+       instruction" error using _bfd_error_handler, not einfo.
+
 2017-07-10  Nick Clifton  <nickc@redhat.com>
 
        * coffcode.h (coff_slurp_symbol_table): Do not include an entry
index 0e992728eafe442d46ca93a027f79dabd6963b0d..1adca7e4815153af285bcc98f9009dcfb99c854a 100644 (file)
@@ -8284,9 +8284,9 @@ ppc_elf_relocate_section (bfd *output_bfd,
                  r_type = R_PPC_GOT16_LO;
                }
              else
-               info->callbacks->einfo
+               _bfd_error_handler
                  /* xgettext:c-format */
-                 (_("%H: error: %s with unexpected instruction %x\n"),
+                 (_("%B(%A+#Lx): error: %s with unexpected instruction %#x"),
                   input_bfd, input_section, rel->r_offset,
                   "R_PPC_ADDR16_HA", insn);
            }
@@ -8319,9 +8319,9 @@ ppc_elf_relocate_section (bfd *output_bfd,
                  rel->r_info = ELF32_R_INFO (0, r_type);
                }
              else
-               info->callbacks->einfo
+               _bfd_error_handler
                  /* xgettext:c-format */
-                 (_("%H: error: %s with unexpected instruction %x\n"),
+                 (_("%B(%A+#Lx): error: %s with unexpected instruction %#x"),
                   input_bfd, input_section, rel->r_offset,
                   "R_PPC_ADDR16_LO", insn);
            }