PR binutils/716
authorNick Clifton <nickc@redhat.com>
Mon, 14 Feb 2005 11:20:37 +0000 (11:20 +0000)
committerNick Clifton <nickc@redhat.com>
Mon, 14 Feb 2005 11:20:37 +0000 (11:20 +0000)
* peicode.h (pe_bfd_copy_private_bfd_data): Copy the large address aware flag
from the input bfd to the output bfd.

bfd/peicode.h

index f72d3f5f7060e6d7b2e2d3ff02e21f66426c7f74..8f4179351eb5bd923d03b3b8f02f1609c37d9250 100644 (file)
@@ -384,6 +384,14 @@ static bfd_boolean
 pe_bfd_copy_private_bfd_data (ibfd, obfd)
      bfd *ibfd, *obfd;
 {
+  /* PR binutils/716: Copy the large address aware flag.
+     XXX: Should we be copying other flags or other fields in the pe_data()
+     structure ?  */
+  if (pe_data (obfd) != NULL
+      && pe_data (ibfd) != NULL
+      && pe_data (ibfd)->real_flags & IMAGE_FILE_LARGE_ADDRESS_AWARE)
+    pe_data (obfd)->real_flags |= IMAGE_FILE_LARGE_ADDRESS_AWARE;
+      
   if (!_bfd_XX_bfd_copy_private_bfd_data_common (ibfd, obfd))
     return FALSE;