Source-Changes-HG archive

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

[src/trunk]: src/lib/csu/common _DYNAMIC is present for static PIE as well, s...



details:   https://anonhg.NetBSD.org/src/rev/80de9ed5a9c3
branches:  trunk
changeset: 324025:80de9ed5a9c3
user:      joerg <joerg%NetBSD.org@localhost>
date:      Thu Jul 12 21:35:12 2018 +0000

description:
_DYNAMIC is present for static PIE as well, so loosen rtld check.

diffstat:

 lib/csu/common/crt0-common.c |  8 +++-----
 1 files changed, 3 insertions(+), 5 deletions(-)

diffs (29 lines):

diff -r 811fab61e76b -r 80de9ed5a9c3 lib/csu/common/crt0-common.c
--- a/lib/csu/common/crt0-common.c      Thu Jul 12 21:22:20 2018 +0000
+++ b/lib/csu/common/crt0-common.c      Thu Jul 12 21:35:12 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: crt0-common.c,v 1.16 2018/03/29 13:23:39 joerg Exp $ */
+/* $NetBSD: crt0-common.c,v 1.17 2018/07/12 21:35:12 joerg Exp $ */
 
 /*
  * Copyright (c) 1998 Christos Zoulas
@@ -36,7 +36,7 @@
  */
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: crt0-common.c,v 1.16 2018/03/29 13:23:39 joerg Exp $");
+__RCSID("$NetBSD: crt0-common.c,v 1.17 2018/07/12 21:35:12 joerg Exp $");
 
 #include <sys/types.h>
 #include <sys/exec.h>
@@ -215,9 +215,7 @@
                __progname = empty_string;
        }
 
-       if (&rtld_DYNAMIC != NULL) {
-               if (obj == NULL)
-                       _FATAL("NULL Obj_Entry pointer in GOT\n");
+       if (&rtld_DYNAMIC != NULL && obj != NULL) {
                if (obj->magic != RTLD_MAGIC)
                        _FATAL("Corrupt Obj_Entry pointer in GOT\n");
                if (obj->version != RTLD_VERSION)



Home | Main Index | Thread Index | Old Index