Subject: Re: Unlocking an unlocked mutex
To: None <>
From: Matthew Mondor <>
List: tech-kern
Date: 10/13/2005 19:15:52
On Thu, 13 Oct 2005 09:31:30 -0700
Bill Studenmund <> wrote:

> My day job is writing an application that uses pthreads. These assertions 
> REALLY help. The problem with unlocking an unlocked mutex is that you most 
> likely just finished modifying data that another thread thought _it_ had 
> exclusive access to. You can end up with problems showing up in whatever 
> code goes to use the unprotected data, so the end error looks like it's 
> miles away from where the bug is.

I strongly concur, I could fix one of my own bugs in a library I used for
several years on Linux without ever knowing it was there, until I decided
to switch the server to NetBSD.  Moreover, I also cought a similar issue
in some of my software when converting it from PTH threads to pthreads on
NetBSD...  So I very like much the current default behavior.


Note: Please only reply on the list, other mail is blocked by default.
Private messages from your address can be allowed by first asking.