aboutsummaryrefslogtreecommitdiff
path: root/elf/dl-close.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2006-10-27 21:01:42 +0000
committerUlrich Drepper <drepper@redhat.com>2006-10-27 21:01:42 +0000
commitffd0e1b7e9b540716e5a98b49157eb1aed231b57 (patch)
tree9bb29c16c4baead035261132ece981507d25dabb /elf/dl-close.c
parent131c4428c67c1147961cfbb8dbcb39a4b341d63f (diff)
downloadglibc-ffd0e1b7e9b540716e5a98b49157eb1aed231b57.tar
glibc-ffd0e1b7e9b540716e5a98b49157eb1aed231b57.tar.gz
glibc-ffd0e1b7e9b540716e5a98b49157eb1aed231b57.tar.bz2
glibc-ffd0e1b7e9b540716e5a98b49157eb1aed231b57.zip
* elf/Makefile: Add rules to build and run tst-thrlock.
* elf/tst-thrlock.c: New file.
Diffstat (limited to 'elf/dl-close.c')
-rw-r--r--elf/dl-close.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/elf/dl-close.c b/elf/dl-close.c
index 51f813defc..fdd9fe6719 100644
--- a/elf/dl-close.c
+++ b/elf/dl-close.c
@@ -110,10 +110,6 @@ void
_dl_close_worker (struct link_map *map)
{
Lmid_t ns = map->l_ns;
- unsigned int i;
-
- /* Acquire the lock. */
- __rtld_lock_lock_recursive (GL(dl_load_lock));
/* One less direct use. */
--map->l_direct_opencount;
@@ -236,7 +232,7 @@ _dl_close_worker (struct link_map *map)
#endif
bool unload_any = false;
unsigned int first_loaded = ~0;
- for (i = 0; i < nloaded; ++i)
+ for (unsigned int i = 0; i < nloaded; ++i)
{
struct link_map *imap = maps[i];
@@ -472,7 +468,7 @@ _dl_close_worker (struct link_map *map)
/* Check each element of the search list to see if all references to
it are gone. */
- for (i = first_loaded; i < nloaded; ++i)
+ for (unsigned int i = first_loaded; i < nloaded; ++i)
{
struct link_map *imap = maps[i];
if (!used[i])