Module Name:    src
Committed By:   christos
Date:           Mon Oct 16 01:50:55 UTC 2017

Modified Files:
        src/sys/kern: exec_elf.c

Log Message:
Setting AT_BASE on static binaries breaks TLS because they assume that
it is 0, will fix it differently.


To generate a diff of this commit:
cvs rdiff -u -r1.91 -r1.92 src/sys/kern/exec_elf.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/kern/exec_elf.c
diff -u src/sys/kern/exec_elf.c:1.91 src/sys/kern/exec_elf.c:1.92
--- src/sys/kern/exec_elf.c:1.91	Sun Oct  8 11:00:40 2017
+++ src/sys/kern/exec_elf.c	Sun Oct 15 21:50:55 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: exec_elf.c,v 1.91 2017/10/08 15:00:40 christos Exp $	*/
+/*	$NetBSD: exec_elf.c,v 1.92 2017/10/16 01:50:55 christos Exp $	*/
 
 /*-
  * Copyright (c) 1994, 2000, 2005, 2015 The NetBSD Foundation, Inc.
@@ -57,7 +57,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(1, "$NetBSD: exec_elf.c,v 1.91 2017/10/08 15:00:40 christos Exp $");
+__KERNEL_RCSID(1, "$NetBSD: exec_elf.c,v 1.92 2017/10/16 01:50:55 christos Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_pax.h"
@@ -815,9 +815,9 @@ exec_elf_makecmds(struct lwp *l, struct 
 		interp = NULL;
 	} else {
 		epp->ep_entry = eh->e_entry;
-		if (is_dyn || (epp->ep_flags & EXEC_FORCEAUX)) {
+		if (epp->ep_flags & EXEC_FORCEAUX) {
 			ap = kmem_zalloc(sizeof(*ap), KM_SLEEP);
-			ap->arg_interp = epp->ep_entryoffset;
+			ap->arg_interp = (vaddr_t)NULL;
 		} else {
 			ap = NULL;
 		}

Reply via email to