pthread_testcancel() causes SEGV

Robert Collins rbcollins@cygwin.com
Mon Sep 16 03:34:00 GMT 2002


On Mon, 2002-09-16 at 19:07, Thomas Pfaff wrote:
> 
> 
> On Tue, 10 Sep 2002, Robert Collins wrote:
> 
> > On Thu, 2002-08-08 at 04:54, Jason Tishler wrote:
> > > Thomas,
> > >
> > > On Wed, Aug 07, 2002 at 09:34:14AM +0200, Thomas Pfaff wrote:
> > > > Thanks for tracking it down.
> > >
> > > No problem.  Thanks for the quick turn around on the patch.  I tested it
> > > and can confirm that it fixes the ipc-daemon service startup problem.
> >
> > Jason,
> > sorry for the *cough* long delay.
> >
> > the attached patch is the 'right way' to deal with this issue IMO. It
> > also gives us full pthread* support for threads created using the win32
> > CreateThread call (although I won't officially support that at this
> > point :}).
> >
> 
> Rob,
> 
> you may have noticed that i have added similar code in my pending pthread
> patches.

I hadn't actually. I simply started at the oldest pending thing, and
reviewed it.

> Anyway, since you return a NULL pointer in pthread_self if something went
> wrong i vote for inclusion of my original patch regardless which patch
> will be applied for pthread_self.

Ah, good catch. I'll return a null object instead.

This object will fail in the method call, and log an error. It shouldn't
segv though, and we won't be introducing a null object check that
doesn't need to exist.

I'm checking in the current code, as I refactored to make some things
clearer before I introduced the NULL object.

Attached is my test program for this..

Rob
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cancelwin32.c
Type: text/x-c
Size: 873 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20020916/be8d7751/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20020916/be8d7751/attachment.sig>


More information about the Cygwin-patches mailing list