* archive.c (_bfd_write_archive_contents): Fix incorrect use of
authorCary Coutant <ccoutant@google.com>
Tue, 22 Apr 2008 00:12:23 +0000 (00:12 +0000)
committerCary Coutant <ccoutant@google.com>
Tue, 22 Apr 2008 00:12:23 +0000 (00:12 +0000)
ARFMAG.

bfd/ChangeLog
bfd/archive.c

index 7171a0c4f29f5d2b081f2eeba537aec97d6d3371..1fa63cdc0259b2d47e14ce8cbde6bd3b2ef4a281 100644 (file)
@@ -1,3 +1,8 @@
+2008-04-21  Cary Coutant  <ccoutant@google.com>
+
+       * archive.c (_bfd_write_archive_contents): Fix incorrect use of
+       ARFMAG.
+
 2008-04-21  Nathan Sidwell  <nathan@codesourcery.com>
 
        * elfxx-mips.c (_bfd_mips_vxworks_adjust_dynamic_symbol): Don't
index 9861ed9ad4511ab66fc12d92501464102413c81a..0ca3db1542e0043a91a9ceb52cbfc7bc79d17603 100644 (file)
@@ -1982,7 +1982,7 @@ _bfd_write_archive_contents (bfd *arch)
        return FALSE;
       if ((elength % 2) == 1)
        {
-         if (bfd_bwrite (ARFMAG, 1, arch) != 1)
+         if (bfd_bwrite (&ARFMAG[1], 1, arch) != 1)
            return FALSE;
        }
     }
@@ -2024,7 +2024,7 @@ _bfd_write_archive_contents (bfd *arch)
 
       if ((arelt_size (current) % 2) == 1)
        {
-         if (bfd_bwrite (ARFMAG, 1, arch) != 1)
+         if (bfd_bwrite (&ARFMAG[1], 1, arch) != 1)
            return FALSE;
        }
     }