This is the mail archive of the
cygwin-patches@cygwin.com
mailing list for the Cygwin project.
RE: [PATCH] pthread cleanup_push,_pop fixes
- From: "Robert Collins" <robert dot collins at syncretize dot net>
- To: "'Thomas Pfaff'" <tpfaff at gmx dot net>,<cygwin-patches at cygwin dot com>
- Date: Mon, 10 Jun 2002 11:05:18 +1000
- Subject: RE: [PATCH] pthread cleanup_push,_pop fixes
This code should have been members of the pthread class. I'm checking in
such a variant.
Thanks again,
Rob
> -----Original Message-----
> From: Thomas Pfaff [mailto:tpfaff@gmx.net]
> Sent: Wednesday, 24 April 2002 8:53 PM
> To: cygwin-patches@cygwin.com
> Subject: [PATCH] pthread cleanup_push,_pop fixes
>
>
> This patch will fix the cleanup_push/pop implementation. It
> is required
> that the pushed handlers will run when a thread exits or is
> cancelled, but
> this did not happen.
> This patch is incremental to my previous patches.
>
> Greetings,
> Thomas
>
> 2002-04-24 Thomas Pfaff <tpfaff@gmx.net>
> * include/pthread.h (__pthread_cleanup_handler): New structure
> (pthread_cleanup_push): Rewritten.
> (pthread_cleanup_pop): Ditto.
> (_pthread_cleanup_push): New prototype
> (_pthread_cleanup_pop) Ditto.
> * pthread.cc: (_pthread_cleanup_push) New function.
> (_pthread_cleanup_pop): Ditto.
>
> * thread.h (__pthread_cleanup_push): New prototype
> (__pthread_cleanup_pop): Ditto.
> (__pthread_cleanup_pop_all): Ditto.
> (pthread::cleanup_handlers): New member.
> * thread.cc (__pthread_cleanup_push): New function.
> (__pthread_cleanup_pop): Ditto.
> (__pthread_cleanup_pop_all): Ditto.
> (__pthread_exit): Run cleanup handlers on exit.
>
> * cygwin.din: Add _pthread_cleanup_push and
> _pthread_cleanup_pop.
>
>