apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William A. Rowe, Jr." <wr...@apache.org>
Subject Re: [PATCH] Thread Locks and SMP boxes
Date Thu, 31 Jul 2003 04:07:09 GMT
At 06:35 PM 7/30/2003, Joe Orton wrote:
>On Wed, Jul 30, 2003 at 01:34:41PM -0500, William Rowe wrote:
>> Because the new patch protects the uninitalization of the mutex while
>> the lock is still held, the only failure scenario that remains is;
>> 1. thread is interrupted (e.g. signal handler) in between the unsetting
>>    of the ownership (and decrement of the refcount) and actually releasing
>>    the mutex.  The interrupt handler attempts to perform a nested lock
>>    and deadlocks because the ownership has already been reset, but
>>    the lock is not yet released.
>Why are you worried about signal handlers using mutexes? Is httpd doing
>this somewhere?

No.  I'm simply pedantic and a paranoid.  Actually, I really get ticked off
by the attitiude expressed by a few individuals that "if the Apache HTTP 
Web Server doesn't do this, APR doesn't need [to deal with] this feature."

Hopefully, at some point, APR will have some applicability beyond HTTP.
In the meantime, it's not unreasonable to deal with the issues that others
might have to confront.

Since the few responses are positive <--> antagonistic, I'll commit both 
the simple and obvious point (2. that you pointed out in an earlier mail)
and the decorative and subtle (1. & 3.) in two separate commits early


View raw message