summary refs log tree commit diff
path: root/elf/dlsym.c
diff options
context:
space:
mode:
Diffstat (limited to 'elf/dlsym.c')
-rw-r--r--elf/dlsym.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/elf/dlsym.c b/elf/dlsym.c
index 1072f16ce1..562df42b34 100644
--- a/elf/dlsym.c
+++ b/elf/dlsym.c
@@ -1,5 +1,5 @@
 /* Look up a symbol in a shared object loaded by `dlopen'.
-   Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
+   Copyright (C) 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -65,8 +65,11 @@ RTLD_NEXT used in code not dynamically loaded"));
       while (l->l_loader)
 	l = l->l_loader;
 
-      args->loadbase = _dl_lookup_symbol_skip (args->name, &args->ref,
-					       &_dl_loaded, NULL, l);
+      {
+	struct link_map *map = l;
+	struct link_map *mapscope[2] = { map, NULL };
+	args->loadbase = _dl_lookup_symbol_skip (args->name, &args->ref,
+						 mapscope, NULL, match);
     }
   else
     {