diff options
author | Andreas Schwab <schwab@redhat.com> | 2010-05-03 08:08:28 -0700 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2010-05-03 08:08:28 -0700 |
commit | 5a2a1d75043138e696222ced4560de2fb90b8024 (patch) | |
tree | 76c2da1388b8787ebabb9e61cf27d7510d1f5a7b /elf/dl-support.c | |
parent | c739ec3d81a34a87d8ae1276eab4f5880afc3476 (diff) | |
download | glibc-5a2a1d75043138e696222ced4560de2fb90b8024.tar.gz glibc-5a2a1d75043138e696222ced4560de2fb90b8024.tar.xz glibc-5a2a1d75043138e696222ced4560de2fb90b8024.zip |
Don't deadlock in __dl_iterate_phdr while (un)loading objects.
Diffstat (limited to 'elf/dl-support.c')
-rw-r--r-- | elf/dl-support.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/elf/dl-support.c b/elf/dl-support.c index 65b25750de..f94d2c4c6e 100644 --- a/elf/dl-support.c +++ b/elf/dl-support.c @@ -166,6 +166,10 @@ const ElfW(Ehdr) *_dl_sysinfo_dso; the loaded object might as well require a call to this function. At this time it is not anymore a problem to modify the tables. */ __rtld_lock_define_initialized_recursive (, _dl_load_lock) +/* This lock is used to keep __dl_iterate_phdr from inspecting the + list of loaded objects while an object is added to or removed from + that list. */ +__rtld_lock_define_initialized_recursive (, _dl_load_write_lock) #ifdef HAVE_AUX_VECTOR |