* elf.c (_bfd_elf_link_hash_copy_indirect): Test ind->root.type
authorAlan Modra <amodra@gmail.com>
Mon, 15 Oct 2001 09:45:48 +0000 (09:45 +0000)
committerAlan Modra <amodra@gmail.com>
Mon, 15 Oct 2001 09:45:48 +0000 (09:45 +0000)
rather than ind->weakdef.
* elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
* elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
* elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
* elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
* elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.

bfd/ChangeLog
bfd/elf.c
bfd/elf32-hppa.c
bfd/elf32-i386.c
bfd/elf32-mips.c
bfd/elf64-ppc.c
bfd/elfxx-ia64.c

index cd8dfa7264cc0fc138bdb9b4f5880c8242f5e0f6..8abfc90d90d36aff80de9eb253225900726fbfa9 100644 (file)
@@ -1,3 +1,13 @@
+2001-10-15  Alan Modra  <amodra@bigpond.net.au>
+
+       * elf.c (_bfd_elf_link_hash_copy_indirect): Test ind->root.type
+       rather than ind->weakdef.
+       * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
+       * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
+       * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
+       * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
+       * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
+
 2001-10-15  Alan Modra  <amodra@bigpond.net.au>
            H.J. Lu  <hjl@gnu.org>
 
index cd2d1692d261b72c0c1b7c9e5fb24675476df9b7..feffd7c85982c0712dde2195e4d9eea7e9a9810b 100644 (file)
--- a/bfd/elf.c
+++ b/bfd/elf.c
@@ -1193,7 +1193,7 @@ _bfd_elf_link_hash_copy_indirect (dir, ind)
        | ELF_LINK_HASH_REF_REGULAR_NONWEAK
        | ELF_LINK_NON_GOT_REF));
 
-  if (dir == ind->weakdef)
+  if (ind->root.type != bfd_link_hash_indirect)
     return;
 
   /* Copy over the global and procedure linkage table refcount entries.
index 65315753b250b96fdd4b383b30fc84eecd2fb708..1417023743814017010198adbdbb468503fda581 100644 (file)
@@ -1149,7 +1149,7 @@ elf32_hppa_copy_indirect_symbol (dir, ind)
          struct elf32_hppa_dyn_reloc_entry **pp;
          struct elf32_hppa_dyn_reloc_entry *p;
 
-         if (dir != ind->weakdef)
+         if (ind->root.type == bfd_link_hash_indirect)
            abort ();
 
          /* Add reloc counts against the weak sym to the strong sym
index f5e64555b101492b583b8774b1a34075817bcd33..fe702b54872d50202fdd003f8a36182e81c00f1e 100644 (file)
@@ -644,7 +644,7 @@ elf_i386_copy_indirect_symbol (dir, ind)
          struct elf_i386_dyn_relocs **pp;
          struct elf_i386_dyn_relocs *p;
 
-         if (dir != ind->weakdef)
+         if (ind->root.type == bfd_link_hash_indirect)
            abort ();
 
          /* Add reloc counts against the weak sym to the strong sym
index 09f77580a322e33740732ad06986a10f24f36320..0bd473dd94b134d1e119c31ae6b4101b7d15c2ed 100644 (file)
@@ -8085,7 +8085,7 @@ _bfd_mips_elf_copy_indirect_symbol (dir, ind)
 
   _bfd_elf_link_hash_copy_indirect (dir, ind);
 
-  if (dir == ind->weakdef)
+  if (ind->root.type != bfd_link_hash_indirect)
     return;
 
   dirmips = (struct mips_elf_link_hash_entry *) dir;
index 1bbd253d1028f047cbac2fb7ddc8c047359c1e7f..59ae522578670a28217551a2d01fa16d0e9b03a6 100644 (file)
@@ -1801,7 +1801,7 @@ ppc64_elf_copy_indirect_symbol (dir, ind)
          struct ppc_dyn_relocs **pp;
          struct ppc_dyn_relocs *p;
 
-         if (dir != ind->weakdef)
+         if (ind->root.type == bfd_link_hash_indirect)
            abort ();
 
          /* Add reloc counts against the weak sym to the strong sym
index e651b5fd80e0e336d23bafed138dda365f230978..5fa95b4d90d2351919412b4441b4db42897a2eda 100644 (file)
@@ -1524,7 +1524,7 @@ elfNN_ia64_hash_copy_indirect (xdir, xind)
         | ELF_LINK_HASH_REF_REGULAR
         | ELF_LINK_HASH_REF_REGULAR_NONWEAK));
 
-  if (xdir == xind->weakdef)
+  if (ind->root.root.type != bfd_link_hash_indirect)
     return;
 
   /* Copy over the got and plt data.  This would have been done