aboutsummaryrefslogtreecommitdiff
path: root/ld/emultempl/hppaelf.em
diff options
context:
space:
mode:
Diffstat (limited to 'ld/emultempl/hppaelf.em')
-rw-r--r--ld/emultempl/hppaelf.em14
1 files changed, 10 insertions, 4 deletions
diff --git a/ld/emultempl/hppaelf.em b/ld/emultempl/hppaelf.em
index 7cb4537..6955796 100644
--- a/ld/emultempl/hppaelf.em
+++ b/ld/emultempl/hppaelf.em
@@ -242,20 +242,26 @@ build_section_lists (lang_statement_union_type *statement)
static void
gld${EMULATION_NAME}_after_allocation (void)
{
+ int ret;
+
/* bfd_elf_discard_info just plays with data and debugging sections,
ie. doesn't affect code size, so we can delay resizing the
sections. It's likely we'll resize everything in the process of
adding stubs. */
- if (bfd_elf_discard_info (link_info.output_bfd, &link_info))
+ ret = bfd_elf_discard_info (link_info.output_bfd, &link_info);
+ if (ret < 0)
+ {
+ einfo ("%X%P: .eh_frame/.stab edit: %E\n");
+ return;
+ }
+ else if (ret > 0)
need_laying_out = 1;
/* If generating a relocatable output file, then we don't
have to examine the relocs. */
if (stub_file != NULL && !link_info.relocatable)
{
- int ret = elf32_hppa_setup_section_lists (link_info.output_bfd,
- &link_info);
-
+ ret = elf32_hppa_setup_section_lists (link_info.output_bfd, &link_info);
if (ret != 0)
{
if (ret < 0)