From e30f2b9828ddff95b687b9818787ab2a99570f11 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Wed, 25 Oct 2000 04:00:08 +0000 Subject: Update. * elf/dl-lookup.c (add_dependency): Fix test to check whether dependency already exists. * elf/Makefile: Add testobj1 and testobj2 as dependencies of testobj6. * elf/loadtest.c (main): Add test at the end that everything is unloaded. * elf/dl-open.c (dl_open_worker): Fix typo in comment. --- elf/dl-lookup.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'elf/dl-lookup.c') diff --git a/elf/dl-lookup.c b/elf/dl-lookup.c index 581c6a6c2b..9e0a25da80 100644 --- a/elf/dl-lookup.c +++ b/elf/dl-lookup.c @@ -97,14 +97,13 @@ add_dependency (struct link_map *undef_map, struct link_map *map) /* Determine whether UNDEF_MAP already has a reference to MAP. First look in the normal dependencies. */ - list = undef_map->l_searchlist.r_list; - act = undef_map->l_searchlist.r_nlist; + list = undef_map->l_initfini; - for (i = 0; i < act; ++i) + for (i = 0; list[i] != NULL; ++i) if (list[i] == map) break; - if (__builtin_expect (i == act, 1)) + if (__builtin_expect (list[i] == NULL, 1)) { /* No normal dependency. See whether we already had to add it to the special list of dynamic dependencies. */ -- cgit v1.2.3