Module Name: src
Committed By: he
Date: Sun May 24 18:29:03 UTC 2009
Modified Files:
src/libexec/ld.elf_so/arch/alpha: alpha_reloc.c
Log Message:
Copy build fix from i386: Fix const issues (cast const pointers
to "const uint8_t *" instead of "caddr_t").
To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/libexec/ld.elf_so/arch/alpha/alpha_reloc.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/libexec/ld.elf_so/arch/alpha/alpha_reloc.c
diff -u src/libexec/ld.elf_so/arch/alpha/alpha_reloc.c:1.31 src/libexec/ld.elf_so/arch/alpha/alpha_reloc.c:1.32
--- src/libexec/ld.elf_so/arch/alpha/alpha_reloc.c:1.31 Thu Jul 24 04:39:25 2008
+++ src/libexec/ld.elf_so/arch/alpha/alpha_reloc.c Sun May 24 18:29:03 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: alpha_reloc.c,v 1.31 2008/07/24 04:39:25 matt Exp $ */
+/* $NetBSD: alpha_reloc.c,v 1.32 2009/05/24 18:29:03 he Exp $ */
/*
* Copyright (c) 2001 Wasabi Systems, Inc.
@@ -62,7 +62,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: alpha_reloc.c,v 1.31 2008/07/24 04:39:25 matt Exp $");
+__RCSID("$NetBSD: alpha_reloc.c,v 1.32 2009/05/24 18:29:03 he Exp $");
#endif /* not lint */
#include <sys/types.h>
@@ -187,7 +187,7 @@
break;
}
}
- relalim = (const Elf_Rela *)((caddr_t)rela + relasz);
+ relalim = (const Elf_Rela *)((const uint8_t *)rela + relasz);
for (; rela < relalim; rela++) {
where = (Elf_Addr *)(relocbase + rela->r_offset);
/* XXX For some reason I see a few GLOB_DAT relocs here. */
@@ -475,7 +475,8 @@
caddr_t
_rtld_bind(const Obj_Entry *obj, Elf_Word reloff)
{
- const Elf_Rela *rela = (const Elf_Rela *)((caddr_t)obj->pltrela + reloff);
+ const Elf_Rela *rela =
+ (const Elf_Rela *)((const uint8_t *)obj->pltrela + reloff);
Elf_Addr result;
int err;