Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Message-ID: <3DEE74C3.1070208@earthlink.net> Date: Wed, 04 Dec 2002 13:33:55 -0800 From: Christophe Galerne User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.1) Gecko/20020826 X-Accept-Language: en-us, en, fr-fr, fr MIME-Version: 1.0 To: cygwin Subject: RE: pthread_mutex_trylock does not lock Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Robert Collins wrote: > On Tue, 2002-12-03 at 23:06, Chris Knight wrote: > > Hello Rob, > > > > I have changed the code, see below. I now set the type to > > PTHREAD_MUTEX_NORMAL but that also does not block. The only documentation > > on cygwin threads say this is the same as PTHREAD_MUTEX_FAST_NP > > What documentation says that? This www.opengroup.org/onlinepubs/7908799/xsh/pthread_mutexattr_settype.html seems to explain that a PT_MUTEX_NORMAL mutex should behave the way Chris expect. If this doc is out-of-date, could you give a pointer to a more accurate source? > We don't support NONRECURSIVE mutex's. I don't know what you mean by > NORECURSIVE threads. Then maybe one should add a comment above pthread.h(55): #define PTHREAD_MUTEX_NORMAL 2 that this option is not supported. Also above pthread.h(57): #define PTHREAD_MUTEX_INITIALIZER (void *)20 a comment that says that a default MUTEX will be recursive might avoid some surprise. =:-D Thanks, Christophe PS: Could you cc me as I am not on the list? Thanks. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/