This is the mail archive of the
mailing list for the Cygwin project.
Re: [PATCH] pthread patch - Thomas Pfaff, please note
- From: Thomas Pfaff <tpfaff at gmx dot net>
- To: cygwin-patches at cygwin dot com
- Date: Mon, 15 Sep 2003 13:18:31 +0200
- Subject: Re: [PATCH] pthread patch - Thomas Pfaff, please note
- References: <20030913012508.GA2870@redhat.com>
Christopher Faylor wrote:
Thomas, I made the change below to stop a SEGV on thread exit as evinced
by the threadidafterfork test in the testsuite.
The problem is that this code overwrites impure_ptr with the contents of
the thread which called fork, which is not the correct thing to do since
_impure_ptr contains global information not present in the calling threads
I hope it makes sense. If there is some better way to do this, please
feel free to check it in. This looked right to me, though.
It is ok for me.
I was not sure whether the thread local reent contains something
important that should be restored after a fork, but with the
_GLOBAL_REENT patches to newlib it is better to keep _impure_ptr unchanged.