This is the mail archive of the
mailing list for the Cygwin project.
Re: [PATCH] fix segv in pthread_mutex::init
- From: Thomas Pfaff <tpfaff at gmx dot net>
- To: Robert Collins <rbcollins at cygwin dot com>
- Cc: cygwin-patches at cygwin dot com
- Date: Thu, 17 Oct 2002 11:31:18 +0200 (Westeuropäische Sommerzeit)
- Subject: Re: [PATCH] fix segv in pthread_mutex::init
On Thu, 17 Oct 2002, Robert Collins wrote:
> On Thu, 2002-10-17 at 18:11, Thomas Pfaff wrote:
> > This patch should fix the segfault in pthread_mutex::init by changing the
> > test order for a valid object and checking for valid initializer object
> > first..
> I'm happy with the verifyable_object change. I'm not happy with the
> pthread_mutex::init change (yet).
> I've checked in the verifyable_object stuff, along with a
> pthread_mutex::init change I am happy with.
> The reason I wasn't happy with your change was threefold:
> 1) there is no need to add scoping to static calls within a class. Doing
> so reduces readability, and should be avoided.
I am sorry, but i have first created the patch in my 1.3.12-4 version and
than ported to the CVS version. I have corrected it in my second posting.
I am still using 1.3.12-4 until i have ported my MTinterface and mutex
patches to the latest version.
> 2) The test was no longer *obvious* at first read, whereas (IMO) what
> I've checked in is.
The isGoodInitializerOrBadObject method looks good.