summary refs log tree commit diff
path: root/elf/loadtest.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/loadtest.c
parent69c3325490f56db660b349d7c04daab6aaea1bf1 (diff)
downloadglibc-42c4f32a44c76d1f4e2b744bf80f495dc36caa87.tar.gz
glibc-42c4f32a44c76d1f4e2b744bf80f495dc36caa87.tar.xz
glibc-42c4f32a44c76d1f4e2b744bf80f495dc36caa87.zip
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/loadtest.c')
-rw-r--r--elf/loadtest.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/elf/loadtest.c b/elf/loadtest.c
index 4a3c4c08be..25b27005f1 100644
--- a/elf/loadtest.c
+++ b/elf/loadtest.c
@@ -83,17 +83,23 @@ main (int argc, char *argv[])
   int debug = argc > 1 && argv[1][0] != '\0';
   int count = TEST_ROUNDS;
   int result = 0;
+  struct link_map *map;
 
   mtrace ();
 
   /* Just a seed.  */
   srandom (TEST_ROUNDS);
 
+  if (debug)
+    {
+      puts ("in the beginning");
+      OUT;
+    }
+
   while (count--)
     {
       int nr = random () % NTESTS;
       int index = tests[nr].index;
-      struct link_map *map;
 
       printf ("%4d: %4d: ", count + 1, nr);
       fflush (stdout);