about summary refs log tree commit diff
path: root/elf/dl-sym.c
diff options
context:
space:
mode:
Diffstat (limited to 'elf/dl-sym.c')
-rw-r--r--elf/dl-sym.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/elf/dl-sym.c b/elf/dl-sym.c
index 43c8274b7d..740bb9a892 100644
--- a/elf/dl-sym.c
+++ b/elf/dl-sym.c
@@ -1,5 +1,5 @@
 /* Look up a symbol in a shared object loaded by `dlopen'.
-   Copyright (C) 1999-2002,2004,2006,2007 Free Software Foundation, Inc.
+   Copyright (C) 1999-2002,2004,2006,2007,2009 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
@@ -95,7 +95,7 @@ do_sym (void *handle, const char *name, void *who,
   struct link_map *match = GL(dl_ns)[LM_ID_BASE]._ns_loaded;
 
   /* Find the highest-addressed object that CALLER is not below.  */
-  for (Lmid_t ns = 0; ns < DL_NNS; ++ns)
+  for (Lmid_t ns = 0; ns < GL(dl_nns); ++ns)
     for (struct link_map *l = GL(dl_ns)[ns]._ns_loaded; l != NULL;
 	 l = l->l_next)
       if (caller >= l->l_map_start && caller < l->l_map_end