* elf.c (assign_file_positions_for_segments): Set next_file_pos even
authorBob Wilson <bob.wilson@acm.org>
Thu, 4 Nov 2004 00:44:23 +0000 (00:44 +0000)
committerBob Wilson <bob.wilson@acm.org>
Thu, 4 Nov 2004 00:44:23 +0000 (00:44 +0000)
if there are no segments.

bfd/ChangeLog
bfd/elf.c

index ad485d2a07cde276fb4bdb8c8dadb4b1d9efe03e..93d96e47932314b32cb38ed3bcd61da25ddb3526 100644 (file)
@@ -1,3 +1,8 @@
+2004-11-03  Bob Wilson  <bob.wilson@acm.org>
+
+       * elf.c (assign_file_positions_for_segments): Set next_file_pos even
+       if there are no segments.
+
 2004-11-02  Daniel Jacobowitz  <dan@debian.org>
 
        * config.bfd: Mark arm-*-oabi and thumb-*-oabi as obsolete.
index b7674e316e68e2d6bb604e4dc943e984e73b133b..a82387ca63834b16fb39a95d47109870b9dd7804 100644 (file)
--- a/bfd/elf.c
+++ b/bfd/elf.c
@@ -3871,7 +3871,10 @@ assign_file_positions_for_segments (bfd *abfd, struct bfd_link_info *link_info)
   elf_elfheader (abfd)->e_phnum = count;
 
   if (count == 0)
-    return TRUE;
+    {
+      elf_tdata (abfd)->next_file_pos = bed->s->sizeof_ehdr;
+      return TRUE;
+    }
 
   /* If we already counted the number of program segments, make sure
      that we allocated enough space.  This happens when SIZEOF_HEADERS
This page took 0.033429 seconds and 4 git commands to generate.