diff options
author | 2015-07-03 11:15:55 +0000 | |
---|---|---|
committer | 2015-07-03 11:15:55 +0000 | |
commit | f110f9d0bcc6c7a3581abe20bd253046ea2ab698 (patch) | |
tree | 93047d4e5400f80e629b93072c41dde73970f267 | |
parent | There are no ${LIBCSRCDIR}/arch/${MACHINE_CPU}/locale directories in (diff) | |
download | wireguard-openbsd-f110f9d0bcc6c7a3581abe20bd253046ea2ab698.tar.xz wireguard-openbsd-f110f9d0bcc6c7a3581abe20bd253046ea2ab698.zip |
Correctly handle relative-type relocations; very old ld.so bug which got
fixed everywhere but on sparc for some unknown reason (and did not cause
any havoc in real life).
-rw-r--r-- | libexec/ld.so/sparc/archdep.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libexec/ld.so/sparc/archdep.h b/libexec/ld.so/sparc/archdep.h index cf3c03743a6..4e967144cb7 100644 --- a/libexec/ld.so/sparc/archdep.h +++ b/libexec/ld.so/sparc/archdep.h @@ -1,4 +1,4 @@ -/* $OpenBSD: archdep.h,v 1.10 2014/11/03 17:50:56 guenther Exp $ */ +/* $OpenBSD: archdep.h,v 1.11 2015/07/03 11:15:55 miod Exp $ */ /* * Copyright (c) 1998 Per Fogelstrom, Opsycon AB @@ -64,7 +64,7 @@ RELOC_RELA(Elf_RelA *r, const Elf_Sym *s, Elf_Addr *p, unsigned long v, { if (ELF_R_TYPE(r->r_info) == R_TYPE(NONE)) { } else if (ELF_R_TYPE(r->r_info) == R_TYPE(RELATIVE)) { - *p += v + r->r_addend; + *p = v + r->r_addend; } else { /* XXX - printf might not work here, but we give it a shot. */ _dl_printf("Unknown bootstrap relocation.\n"); |