Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 28 Nov 1998 21:31:16 -0500 (EST)
From:      Daniel Eischen <eischen@vigrid.com>
To:        cvs-all@FreeBSD.ORG, cvs-committers@FreeBSD.ORG, eivind@FreeBSD.ORG, lists@tar.com
Subject:   Re: cvs commit: src/include pthread.h src/lib/libc_r/uthread uthread_mattr_kind_np.c uthread_mutex.c
Message-ID:  <199811290231.VAA28198@pcnet1.pcnet.com>

next in thread | raw e-mail | index | archive | help
> >eivind      1998/11/28 15:52:59 PST
> >
> >  Modified files:
> >    include              pthread.h 
> >    lib/libc_r/uthread   uthread_mattr_kind_np.c uthread_mutex.c 
> >  Log:
> >  Add support for pthread_mutexattr_settype().  As a side effect of
> >  testing this, fix MUTEX_TYPE_COUNTING_FAST.  Recursive locks now work.
>                                                 ^^^^^^^^^^^^^^^^^^^^^^^^
> You might want to check localtime.c in libc.  I seem to recall from
> looking at this a couple of weeks ago that the "thread safe", ie.
> libc_r, implementation makes recursive calls to pthread_mutex_lock.
> Therefore, its possible this change will break some of the localtime
> related functions.  If so, it could be fixed by having localtime.c
> use recursive mutexes, or better yet, by rewriting it so it doesn't
> make recursive calls to pthread_mutex_lock.

And can we also make a default mutex an error checking mutex?
Both POSIX and Single UNIX Spec 2 allow this.  SS2 allows that
you can map PTHREAD_MUTEX_DEFAULT to any one of the other
mutex types - it should be mapped to PTHREAD_MUTEX_ERRORCHECK.

If at all possible, we should let the programmer know that he's
hit a deadlock condition.

Dan Eischen
eischen@vigrid.com

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?199811290231.VAA28198>