This is the mail archive of the
libc-ports@sources.redhat.com
mailing list for the libc-ports project.
Close bug 11615?
- From: OndÅej BÃlka <neleai at seznam dot cz>
- To: David Miller <davem at davemloft dot net>
- Cc: libc-ports at sourceware dot org
- Date: Sat, 12 Oct 2013 22:05:24 +0200
- Subject: Close bug 11615?
- Authentication-results: sourceware.org; auth=none
Hi David,
Following patch is for handling broken binaries on mips with RLD_MAP set
to 0. This was caused by bug in binutils which was fixed two years ago,
see. I wanted to be sure that it is no longer relevant.
https://sourceware.org/bugzilla/show_bug.cgi?id=11615
diff --git a/sysdeps/mips/dl-machine.h b/sysdeps/mips/dl-machine.h
index 123b4d6..3bed59c 100644
--- a/sysdeps/mips/dl-machine.h
+++ b/sysdeps/mips/dl-machine.h
@@ -70,7 +70,8 @@
/* If there is a DT_MIPS_RLD_MAP entry in the dynamic section, fill it
in
with the run-time address of the r_debug structure */
#define ELF_MACHINE_DEBUG_SETUP(l,r) \
-do { if ((l)->l_info[DT_MIPS (RLD_MAP)]) \
+do { if ((l)->l_info[DT_MIPS (RLD_MAP)] && \
+ (l)->l_info[DT_MIPS (RLD_MAP)]->d_un.d_ptr) \
*(ElfW(Addr) *)((l)->l_info[DT_MIPS (RLD_MAP)]->d_un.d_ptr) = \
(ElfW(Addr)) (r); \
} while (0)