summaryrefslogtreecommitdiff
path: root/bfd/elf32-i386.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2002-07-31 15:04:06 +0000
committerJakub Jelinek <jakub@redhat.com>2002-07-31 15:04:06 +0000
commit112af99eebfab494a95f95184df654fbe8441be1 (patch)
treeb62f7132cf1c48358a6ea44573b4b42e7350d1f8 /bfd/elf32-i386.c
parent3243fb9c97fc0add2066ef83c23487d0903d0f0a (diff)
downloadgdb-112af99eebfab494a95f95184df654fbe8441be1.tar.gz
* elf32-i386.c (elf_i386_copy_indirect_symbol): Swap tls_type
if _bfd_elf_link_hash_copy_indirect will swap got.refcount.
Diffstat (limited to 'bfd/elf32-i386.c')
-rw-r--r--bfd/elf32-i386.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/bfd/elf32-i386.c b/bfd/elf32-i386.c
index 7f26fabb368..997bf372270 100644
--- a/bfd/elf32-i386.c
+++ b/bfd/elf32-i386.c
@@ -809,6 +809,12 @@ elf_i386_copy_indirect_symbol (dir, ind)
eind->dyn_relocs = NULL;
}
+ if (ind->root.type == bfd_link_hash_indirect
+ && dir->got.refcount <= 0)
+ {
+ edir->tls_type = eind->tls_type;
+ eind->tls_type = GOT_UNKNOWN;
+ }
_bfd_elf_link_hash_copy_indirect (dir, ind);
}