(pthread_handle_create): Initialize self-reference in descriptor.

This commit is contained in:
Ulrich Drepper 2002-07-15 02:02:58 +00:00
parent 3dbd4a6f15
commit a4eaf7fb25
1 changed files with 1 additions and 0 deletions

View File

@ -635,6 +635,7 @@ static int pthread_handle_create(pthread_t *thread, const pthread_attr_t *attr,
new_thread_id = sseg + pthread_threads_counter;
/* Initialize the thread descriptor. Elements which have to be
initialized to zero already have this value. */
new_thread->p_header.data.tcb = new_thread;
new_thread->p_tid = new_thread_id;
new_thread->p_lock = &(__pthread_handles[sseg].h_lock);
new_thread->p_cancelstate = PTHREAD_CANCEL_ENABLE;