aboutsummaryrefslogtreecommitdiff
path: root/elf/dl-tls.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2008-10-31 20:50:16 +0000
committerUlrich Drepper <drepper@redhat.com>2008-10-31 20:50:16 +0000
commit41e25904a520d49ba14d7e9a0a7ea84731572ebd (patch)
tree953dbd8a651ae74dde22e8b277592a2f9057b5d5 /elf/dl-tls.c
parente148a6443cfeb032ac872d4134e4d41446932879 (diff)
downloadglibc-41e25904a520d49ba14d7e9a0a7ea84731572ebd.zip
glibc-41e25904a520d49ba14d7e9a0a7ea84731572ebd.tar.gz
glibc-41e25904a520d49ba14d7e9a0a7ea84731572ebd.tar.bz2
* elf/dl-tls.c (__tls_get_addr): After calling _dl_update_slotinfocvs/fedora-glibc-20081031T2102
refetch dtv, as it might have changed. * elf/Makefile: Add rules to build and run tst-tls18. * elf/tst-tls18.c: New test. * elf/tst-tlsmod18a.c: New file.
Diffstat (limited to 'elf/dl-tls.c')
-rw-r--r--elf/dl-tls.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/elf/dl-tls.c b/elf/dl-tls.c
index e234a0a..824adc1 100644
--- a/elf/dl-tls.c
+++ b/elf/dl-tls.c
@@ -756,7 +756,10 @@ __tls_get_addr (GET_ADDR_ARGS)
void *p;
if (__builtin_expect (dtv[0].counter != GL(dl_tls_generation), 0))
- the_map = _dl_update_slotinfo (GET_ADDR_MODULE);
+ {
+ the_map = _dl_update_slotinfo (GET_ADDR_MODULE);
+ dtv = THREAD_DTV ();
+ }
p = dtv[GET_ADDR_MODULE].pointer.val;