Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 Jun 2001 04:46:39 -0700
From:      Jason Evans <jasone@canonware.com>
To:        Jason Evans <jasone@FreeBSD.org>
Cc:        cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/lib/libc_r/uthread pthread_private.h uthread_find_thread.c uthread_join.c
Message-ID:  <20010627044639.J47186@canonware.com>
In-Reply-To: <200106271141.f5RBfGm89143@freefall.freebsd.org>; from jasone@FreeBSD.org on Wed, Jun 27, 2001 at 04:41:16AM -0700
References:  <200106271141.f5RBfGm89143@freefall.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Jun 27, 2001 at 04:41:16AM -0700, Jason Evans wrote:
> jasone      2001/06/27 04:41:16 PDT
> 
>   Modified files:
>     lib/libc_r/uthread   pthread_private.h uthread_find_thread.c 
>                          uthread_join.c 
>   Log:
>   Fix a race condition in pthread_join().  All of the following must occur
>   atomically:
>   
>   1) Search _thread_list for the thread to join.
>   2) Search _dead_list for the thread to join.
>   3) Set the running thread as the joiner.

This is a pretty serious problem, and has surely caused mysterious program
hangs for people besides myself.  I will be out of town until 4 July, and
plan to MFC this fix upon returning.  A patch for RELENG_4 is available for
those who can't wait:

http://people.freebsd.org/~jasone/diffs/join_race_releng_4.diff

Jason

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010627044639.J47186>