about summary refs log tree commit diff
path: root/elf/dl-object.c
diff options
context:
space:
mode:
Diffstat (limited to 'elf/dl-object.c')
-rw-r--r--elf/dl-object.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/elf/dl-object.c b/elf/dl-object.c
index d9dd692be2..297f30ecee 100644
--- a/elf/dl-object.c
+++ b/elf/dl-object.c
@@ -64,6 +64,8 @@ _dl_new_object (char *realname, const char *libname, int type,
       /* Add the global scope.  */
       new->l_scope[idx++] = &_dl_loaded->l_searchlist;
     }
+  else
+    _dl_loaded = new;
   /* This is our local scope.  */
   if (loader != NULL)
     {