aboutsummaryrefslogtreecommitdiff
path: root/ld/emultempl/elf32.em
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2000-09-20 04:20:26 +0000
committerAlan Modra <amodra@gmail.com>2000-09-20 04:20:26 +0000
commitb3ea35849fbbdfb9a2396e4e9369d28f8597338a (patch)
tree5e660b2b5007cb997e3f609c349ee48a32c6de54 /ld/emultempl/elf32.em
parent6091b433d78be72dd7970fcd91822ae2b9db7a81 (diff)
downloadgdb-b3ea35849fbbdfb9a2396e4e9369d28f8597338a.zip
gdb-b3ea35849fbbdfb9a2396e4e9369d28f8597338a.tar.gz
gdb-b3ea35849fbbdfb9a2396e4e9369d28f8597338a.tar.bz2
Handle out of memory situations.
Diffstat (limited to 'ld/emultempl/elf32.em')
-rw-r--r--ld/emultempl/elf32.em10
1 files changed, 7 insertions, 3 deletions
diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em
index c7ba497..fe4966d 100644
--- a/ld/emultempl/elf32.em
+++ b/ld/emultempl/elf32.em
@@ -1092,9 +1092,13 @@ gld${EMULATION_NAME}_place_orphan (file, s)
loadable or allocateable characteristics. */
outsecname = secname;
if (bfd_get_section_by_name (output_bfd, outsecname) != NULL)
- outsecname = bfd_get_unique_section_name (output_bfd,
- outsecname,
- &count);
+ {
+ outsecname = bfd_get_unique_section_name (output_bfd,
+ outsecname,
+ &count);
+ if (outsecname == NULL)
+ einfo ("%F%P: place_orphan failed: %E\n");
+ }
/* Start building a list of statements for this section.
First save the current statement pointer. */