bfd/
[deliverable/binutils-gdb.git] / bfd / i386msdos.c
index cd41d0b049fda53f9d894800aac3440c8c2bad42..65080e3c6d50037ca36643c4c180b4eedc460f3f 100644 (file)
@@ -83,12 +83,11 @@ msdos_write_object_contents (abfd)
   /* Find the total size of the program on disk and in memory.  */
   for (sec = abfd->sections; sec != (asection *) NULL; sec = sec->next)
     {
-      if (bfd_get_section_size (sec) == 0)
+      if (sec->size == 0)
         continue;
       if (bfd_get_section_flags (abfd, sec) & SEC_ALLOC)
         {
-         bfd_vma sec_vma = (bfd_get_section_vma (abfd, sec)
-                            + bfd_get_section_size (sec));
+         bfd_vma sec_vma = bfd_get_section_vma (abfd, sec) + sec->size;
          if (sec_vma > high_vma)
            high_vma = sec_vma;
        }
@@ -96,7 +95,7 @@ msdos_write_object_contents (abfd)
         {
          file_ptr sec_end = (sizeof (hdr)
                              + bfd_get_section_vma (abfd, sec)
-                             + bfd_get_section_size (sec));
+                             + sec->size);
          if (sec_end > outfile_size)
            outfile_size = sec_end;
        }
This page took 0.026001 seconds and 4 git commands to generate.