diff options
Diffstat (limited to 'libexec/rtld-elf')
-rw-r--r-- | libexec/rtld-elf/alpha/reloc.c | 2 | ||||
-rw-r--r-- | libexec/rtld-elf/amd64/reloc.c | 2 | ||||
-rw-r--r-- | libexec/rtld-elf/i386/reloc.c | 2 | ||||
-rw-r--r-- | libexec/rtld-elf/ia64/reloc.c | 2 | ||||
-rw-r--r-- | libexec/rtld-elf/powerpc/reloc.c | 6 | ||||
-rw-r--r-- | libexec/rtld-elf/sparc64/reloc.c | 2 |
6 files changed, 1 insertions, 15 deletions
diff --git a/libexec/rtld-elf/alpha/reloc.c b/libexec/rtld-elf/alpha/reloc.c index c1a71cf..535419c 100644 --- a/libexec/rtld-elf/alpha/reloc.c +++ b/libexec/rtld-elf/alpha/reloc.c @@ -162,8 +162,6 @@ reloc_non_plt(Obj_Entry *obj, Obj_Entry *obj_rtld) cache = mmap(NULL, bytes, PROT_READ|PROT_WRITE, MAP_ANON, -1, 0); if (cache == MAP_FAILED) cache = NULL; - if (cache != NULL) - memset(cache, 0, bytes); /* Perform relocations without addend if there are any: */ rellim = (const Elf_Rel *) ((caddr_t) obj->rel + obj->relsize); diff --git a/libexec/rtld-elf/amd64/reloc.c b/libexec/rtld-elf/amd64/reloc.c index f8457b3..6778574 100644 --- a/libexec/rtld-elf/amd64/reloc.c +++ b/libexec/rtld-elf/amd64/reloc.c @@ -125,8 +125,6 @@ reloc_non_plt(Obj_Entry *obj, Obj_Entry *obj_rtld) cache = mmap(NULL, bytes, PROT_READ|PROT_WRITE, MAP_ANON, -1, 0); if (cache == MAP_FAILED) cache = NULL; - if (cache != NULL) - memset(cache, 0, bytes); rellim = (const Elf_Rel *) ((caddr_t) obj->rel + obj->relsize); for (rel = obj->rel; rel < rellim; rel++) { diff --git a/libexec/rtld-elf/i386/reloc.c b/libexec/rtld-elf/i386/reloc.c index f8457b3..6778574 100644 --- a/libexec/rtld-elf/i386/reloc.c +++ b/libexec/rtld-elf/i386/reloc.c @@ -125,8 +125,6 @@ reloc_non_plt(Obj_Entry *obj, Obj_Entry *obj_rtld) cache = mmap(NULL, bytes, PROT_READ|PROT_WRITE, MAP_ANON, -1, 0); if (cache == MAP_FAILED) cache = NULL; - if (cache != NULL) - memset(cache, 0, bytes); rellim = (const Elf_Rel *) ((caddr_t) obj->rel + obj->relsize); for (rel = obj->rel; rel < rellim; rel++) { diff --git a/libexec/rtld-elf/ia64/reloc.c b/libexec/rtld-elf/ia64/reloc.c index be846c1..8c63073 100644 --- a/libexec/rtld-elf/ia64/reloc.c +++ b/libexec/rtld-elf/ia64/reloc.c @@ -231,8 +231,6 @@ reloc_non_plt(Obj_Entry *obj, Obj_Entry *obj_rtld) cache = mmap(NULL, bytes, PROT_READ|PROT_WRITE, MAP_ANON, -1, 0); if (cache == MAP_FAILED) cache = NULL; - if (cache != NULL) - memset(cache, 0, bytes); /* * When relocating rtld itself, we need to avoid using malloc. diff --git a/libexec/rtld-elf/powerpc/reloc.c b/libexec/rtld-elf/powerpc/reloc.c index 22613a0..0384600 100644 --- a/libexec/rtld-elf/powerpc/reloc.c +++ b/libexec/rtld-elf/powerpc/reloc.c @@ -233,12 +233,8 @@ reloc_non_plt(Obj_Entry *obj, Obj_Entry *obj_rtld) * limited amounts of stack available so we cannot use alloca(). */ cache = mmap(NULL, bytes, PROT_READ|PROT_WRITE, MAP_ANON, -1, 0); - if (cache == MAP_FAILED) { + if (cache == MAP_FAILED) cache = NULL; - } - if (cache != NULL) { - memset(cache, 0, obj->nchains * sizeof(SymCache)); - } /* * From the SVR4 PPC ABI: diff --git a/libexec/rtld-elf/sparc64/reloc.c b/libexec/rtld-elf/sparc64/reloc.c index e4c78b6..5808fd3 100644 --- a/libexec/rtld-elf/sparc64/reloc.c +++ b/libexec/rtld-elf/sparc64/reloc.c @@ -261,8 +261,6 @@ reloc_non_plt(Obj_Entry *obj, Obj_Entry *obj_rtld) cache = mmap(NULL, bytes, PROT_READ|PROT_WRITE, MAP_ANON, -1, 0); if (cache == MAP_FAILED) cache = NULL; - if (cache != NULL) - memset(cache, 0, obj->nchains * sizeof(SymCache)); relalim = (const Elf_Rela *)((caddr_t)obj->rela + obj->relasize); for (rela = obj->rela; rela < relalim; rela++) { |