Blame SOURCES/glibc-rh808337.patch

b9ba6d
commit 6a5ee1029b3966c5ae9adaaa881e255b2880f511
b9ba6d
Author: Ulrich Drepper <drepper@gmail.com>
b9ba6d
Date:   Sun Mar 6 00:01:50 2011 -0500
b9ba6d
b9ba6d
    Fix loading first object along a path when tracing.
b9ba6d
b9ba6d
diff --git a/elf/dl-load.c b/elf/dl-load.c
b9ba6d
index 1ad16a0..f866066 100644
b9ba6d
--- a/elf/dl-load.c
b9ba6d
+++ b/elf/dl-load.c
b9ba6d
@@ -2111,7 +2111,9 @@ _dl_map_object (struct link_map *loader, const char *name,
b9ba6d
 	    {
b9ba6d
 #ifdef SHARED
b9ba6d
 	      // XXX Correct to unconditionally default to namespace 0?
b9ba6d
-	      l = loader ?: GL(dl_ns)[LM_ID_BASE]._ns_loaded;
b9ba6d
+	      l = (loader
b9ba6d
+		   ?: GL(dl_ns)[LM_ID_BASE]._ns_loaded
b9ba6d
+		   ?: &GL(dl_rtld_map));
b9ba6d
 #else
b9ba6d
 	      l = loader;
b9ba6d
 #endif