Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/libexec/ld.elf_so/arch/mips Don't or the got object in, just...



details:   https://anonhg.NetBSD.org/src/rev/03eb6f46e03a
branches:  trunk
changeset: 953341:03eb6f46e03a
user:      christos <christos%NetBSD.org@localhost>
date:      Sat Mar 06 20:11:08 2021 +0000

description:
Don't or the got object in, just assign it. Fixes cc -mabi=64 hello.c -lcrypto
Now all 64 bit binaries work, and I tested that we did not break the 32 bit
ones
XXX: That 0x80000000 seems wrong for 64 bit stuff.

diffstat:

 libexec/ld.elf_so/arch/mips/mips_reloc.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 9662757a7c47 -r 03eb6f46e03a libexec/ld.elf_so/arch/mips/mips_reloc.c
--- a/libexec/ld.elf_so/arch/mips/mips_reloc.c  Sat Mar 06 20:09:39 2021 +0000
+++ b/libexec/ld.elf_so/arch/mips/mips_reloc.c  Sat Mar 06 20:11:08 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: mips_reloc.c,v 1.73 2019/11/03 03:15:59 christos Exp $ */
+/*     $NetBSD: mips_reloc.c,v 1.74 2021/03/06 20:11:08 christos Exp $ */
 
 /*
  * Copyright 1997 Michael L. Hitch <mhitch%montana.edu@localhost>
@@ -30,7 +30,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: mips_reloc.c,v 1.73 2019/11/03 03:15:59 christos Exp $");
+__RCSID("$NetBSD: mips_reloc.c,v 1.74 2021/03/06 20:11:08 christos Exp $");
 #endif /* not lint */
 
 #include <sys/types.h>
@@ -129,7 +129,7 @@
 {
        obj->pltgot[0] = (Elf_Addr) &_rtld_bind_start;
        /* XXX only if obj->pltgot[1] & 0x80000000 ?? */
-       obj->pltgot[1] |= (Elf_Addr) obj;
+       obj->pltgot[1] = (Elf_Addr) obj;
 }
 
 void



Home | Main Index | Thread Index | Old Index