summaryrefslogtreecommitdiff
path: root/elf/dl-lookup.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2000-10-24 07:36:55 +0000
committerUlrich Drepper <drepper@redhat.com>2000-10-24 07:36:55 +0000
commit42c4f32a44c76d1f4e2b744bf80f495dc36caa87 (patch)
tree475224614ae3e30c27dc1889e86468080c48cf9c /elf/dl-lookup.c
parent69c3325490f56db660b349d7c04daab6aaea1bf1 (diff)
Update.
2000-10-24 Ulrich Drepper <drepper@redhat.com> Complete revamp of the reference counter handling. * include/link.h (struct link_map): Add l_idx field. * elf/dl-close.c: Handle decrementing of reference counters more correctly. If necessary decrement reference counters of dependencies of dependencies. * elf/dl-lookup.c (add_dependency): Only increment reference counter of the object itself and not also its dependencies. * elf/dl-open.c: Increment reference counters here. * elf/dl-deps.c: Remove reference counter handling here. * elf/dl-load.c: Likewise. * elf/rtld.c: Adjust for _dl_map_deps not handling reference counters. * elf/loadtest.c: Print loaded objects at the beginning.
Diffstat (limited to 'elf/dl-lookup.c')
-rw-r--r--elf/dl-lookup.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/elf/dl-lookup.c b/elf/dl-lookup.c
index d9476817c3..1284e2b3dc 100644
--- a/elf/dl-lookup.c
+++ b/elf/dl-lookup.c
@@ -160,11 +160,7 @@ add_dependency (struct link_map *undef_map, struct link_map *map)
if (__builtin_expect (act < undef_map->l_reldepsmax, 1))
undef_map->l_reldeps[undef_map->l_reldepsact++] = map;
- /* And increment the counter in the referenced object
- and its dependencies. */
- if (map->l_initfini != NULL)
- for (j = 1; map->l_initfini[j] != NULL; ++j)
- ++map->l_initfini[j]->l_opencount;
+ /* And increment the counter in the referenced object. */
++map->l_opencount;
/* Display information if we are debugging. */