From 86a4952b1461aa668cb0fd55ececbb691eefdb12 Mon Sep 17 00:00:00 2001 From: Ulrich Weigand Date: Wed, 14 May 2008 16:00:38 +0000 Subject: [PATCH] * elf32-ppc.c (ppc_elf_get_synthetic_symtab): Fix memset calls. * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Likewise. --- bfd/ChangeLog | 5 +++++ bfd/elf32-ppc.c | 4 ++-- bfd/elf64-ppc.c | 2 +- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/bfd/ChangeLog b/bfd/ChangeLog index fa42524685f..7f8f3292335 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,8 @@ +2008-05-14 Ulrich Weigand + + * elf32-ppc.c (ppc_elf_get_synthetic_symtab): Fix memset calls. + * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Likewise. + 2008-05-14 Alan Modra * Makefile.am: Run "make dep-am". diff --git a/bfd/elf32-ppc.c b/bfd/elf32-ppc.c index 218a7cab5c9..2dafde7d0d8 100644 --- a/bfd/elf32-ppc.c +++ b/bfd/elf32-ppc.c @@ -2464,7 +2464,7 @@ ppc_elf_get_synthetic_symtab (bfd *abfd, long symcount, asymbol **syms, } /* Add a symbol at the start of the glink branch table. */ - memset (s, sizeof *s, 0); + memset (s, 0, sizeof *s); s->the_bfd = abfd; s->flags = BSF_GLOBAL; s->section = glink; @@ -2478,7 +2478,7 @@ ppc_elf_get_synthetic_symtab (bfd *abfd, long symcount, asymbol **syms, if (resolv_vma) { /* Add a symbol for the glink PLT resolver. */ - memset (s, sizeof *s, 0); + memset (s, 0, sizeof *s); s->the_bfd = abfd; s->flags = BSF_GLOBAL; s->section = glink; diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c index 9b11c37eb13..8a26c8daffd 100644 --- a/bfd/elf64-ppc.c +++ b/bfd/elf64-ppc.c @@ -3143,7 +3143,7 @@ ppc64_elf_get_synthetic_symtab (bfd *abfd, if (resolv_vma) { /* Add a symbol for the main glink trampoline. */ - memset (s, sizeof *s, 0); + memset (s, 0, sizeof *s); s->the_bfd = abfd; s->flags = BSF_GLOBAL; s->section = glink; -- 2.30.2