diff options
author | Roland McGrath <roland@redhat.com> | 2009-11-22 20:42:53 -0800 |
---|---|---|
committer | Roland McGrath <roland@redhat.com> | 2009-12-09 01:01:28 -0800 |
commit | 6f1672172c9c9e5eb5afdcf521e3528b38b2e2dd (patch) | |
tree | f1ca70b5d1c32d593b0c2e825f10c56b49d14c06 /nptl_db/td_thr_tsd.c | |
parent | ee1a7fabb4e0abd3e73e828ce326dcb5fd38b874 (diff) | |
download | glibc-6f1672172c9c9e5eb5afdcf521e3528b38b2e2dd.tar.gz glibc-6f1672172c9c9e5eb5afdcf521e3528b38b2e2dd.tar.xz glibc-6f1672172c9c9e5eb5afdcf521e3528b38b2e2dd.zip |
Make libthread_db work without libpthread, just enough for TLS decoding. roland/nptl_db
Diffstat (limited to 'nptl_db/td_thr_tsd.c')
-rw-r--r-- | nptl_db/td_thr_tsd.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/nptl_db/td_thr_tsd.c b/nptl_db/td_thr_tsd.c index 08f617b7d2..9082ce3101 100644 --- a/nptl_db/td_thr_tsd.c +++ b/nptl_db/td_thr_tsd.c @@ -1,5 +1,5 @@ /* Get a thread-specific data pointer for a thread. - Copyright (C) 1999,2001,2002,2003 Free Software Foundation, Inc. + Copyright (C) 1999,2001,2002,2003,2009 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper <drepper@redhat.com>, 1999. @@ -31,8 +31,11 @@ td_thr_tsd (const td_thrhandle_t *th, const thread_key_t tk, void **data) LOG ("td_thr_tsd"); + err = _td_ta_check_nptl (th->th_ta_p); + /* Get the key entry. */ - err = DB_GET_VALUE (tk_seq, th->th_ta_p, __pthread_keys, tk); + if (err == TD_OK) + err = DB_GET_VALUE (tk_seq, th->th_ta_p, __pthread_keys, tk); if (err == TD_NOAPLIC) return TD_BADKEY; if (err != TD_OK) |