diff options
author | Alan Modra <amodra@gmail.com> | 2002-10-11 08:33:11 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2002-10-11 08:33:11 +0000 |
commit | 14a793b2f2d16ac51e6ac53e817a60a520a83200 (patch) | |
tree | f61585eba76e731da279ee2a157c23c0496c0354 /bfd/elf64-alpha.c | |
parent | 2d801b0fa01bf6af6d34f000ab55096ff1064acc (diff) | |
download | gdb-14a793b2f2d16ac51e6ac53e817a60a520a83200.zip gdb-14a793b2f2d16ac51e6ac53e817a60a520a83200.tar.gz gdb-14a793b2f2d16ac51e6ac53e817a60a520a83200.tar.bz2 |
Fix numerous occurrences of
warning: dereferencing type-punned pointer will break strict-aliasing rules
Diffstat (limited to 'bfd/elf64-alpha.c')
-rw-r--r-- | bfd/elf64-alpha.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/bfd/elf64-alpha.c b/bfd/elf64-alpha.c index e1d095d..5973017 100644 --- a/bfd/elf64-alpha.c +++ b/bfd/elf64-alpha.c @@ -2480,6 +2480,7 @@ elf64_alpha_create_dynamic_sections (abfd, info) { asection *s; struct elf_link_hash_entry *h; + struct bfd_link_hash_entry *bh; /* We need to create .plt, .rela.plt, .got, and .rela.got sections. */ @@ -2495,13 +2496,13 @@ elf64_alpha_create_dynamic_sections (abfd, info) /* Define the symbol _PROCEDURE_LINKAGE_TABLE_ at the start of the .plt section. */ - h = NULL; + bh = NULL; if (! (_bfd_generic_link_add_one_symbol (info, abfd, "_PROCEDURE_LINKAGE_TABLE_", BSF_GLOBAL, s, (bfd_vma) 0, (const char *) NULL, false, - get_elf_backend_data (abfd)->collect, - (struct bfd_link_hash_entry **) &h))) + get_elf_backend_data (abfd)->collect, &bh))) return false; + h = (struct elf_link_hash_entry *) bh; h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR; h->type = STT_OBJECT; @@ -2539,13 +2540,13 @@ elf64_alpha_create_dynamic_sections (abfd, info) dynobj's .got section. We don't do this in the linker script because we don't want to define the symbol if we are not creating a global offset table. */ - h = NULL; + bh = NULL; if (!(_bfd_generic_link_add_one_symbol (info, abfd, "_GLOBAL_OFFSET_TABLE_", BSF_GLOBAL, alpha_elf_tdata(abfd)->got, (bfd_vma) 0, (const char *) NULL, - false, get_elf_backend_data (abfd)->collect, - (struct bfd_link_hash_entry **) &h))) + false, get_elf_backend_data (abfd)->collect, &bh))) return false; + h = (struct elf_link_hash_entry *) bh; h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR; h->type = STT_OBJECT; |