Module Name:    src
Committed By:   christos
Date:           Thu Dec  1 18:21:39 UTC 2016

Modified Files:
        src/libexec/ld.elf_so: rtld.c

Log Message:
n dl_iterate_phdr return the path not the name.


To generate a diff of this commit:
cvs rdiff -u -r1.181 -r1.182 src/libexec/ld.elf_so/rtld.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/rtld.c
diff -u src/libexec/ld.elf_so/rtld.c:1.181 src/libexec/ld.elf_so/rtld.c:1.182
--- src/libexec/ld.elf_so/rtld.c:1.181	Thu Dec  1 09:29:15 2016
+++ src/libexec/ld.elf_so/rtld.c	Thu Dec  1 13:21:39 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: rtld.c,v 1.181 2016/12/01 14:29:15 christos Exp $	 */
+/*	$NetBSD: rtld.c,v 1.182 2016/12/01 18:21:39 christos Exp $	 */
 
 /*
  * Copyright 1996 John D. Polstra.
@@ -40,7 +40,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: rtld.c,v 1.181 2016/12/01 14:29:15 christos Exp $");
+__RCSID("$NetBSD: rtld.c,v 1.182 2016/12/01 18:21:39 christos Exp $");
 #endif /* not lint */
 
 #include <sys/param.h>
@@ -1402,8 +1402,7 @@ dl_iterate_phdr(int (*callback)(struct d
 	for (obj = _rtld_objlist;  obj != NULL;  obj = obj->next) {
 		phdr_info.dlpi_addr = (Elf_Addr)obj->relocbase;
 		/* XXX: wrong but not fixing it yet */
-		phdr_info.dlpi_name = SIMPLEQ_FIRST(&obj->names) ?
-		    SIMPLEQ_FIRST(&obj->names)->name : obj->path;
+		phdr_info.dlpi_name = obj->path;
 		phdr_info.dlpi_phdr = obj->phdr;
 		phdr_info.dlpi_phnum = obj->phsize / sizeof(obj->phdr[0]);
 #if defined(__HAVE_TLS_VARIANT_I) || defined(__HAVE_TLS_VARIANT_II)

Reply via email to