Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2002-10-20 22:17:43 +0400
committerChristopher Faylor <me@cgf.cx>2002-10-20 22:17:43 +0400
commitccefaab1d5735466b54f8c5dd279a310d6020a77 (patch)
treebb1926bbc861ff38f55d3d398480fdad1dd2a431
parentcf70a7e372934cf8adecf42ce98fabf0c430b93d (diff)
* cygthread.cc (cygthread::stub): Fix typo.
(cygthread::terminate): Don't zero thread handle prior to using it.
-rw-r--r--winsup/cygwin/ChangeLog5
-rw-r--r--winsup/cygwin/cygthread.cc7
2 files changed, 9 insertions, 3 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index 40ffeaedf..942db019c 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,5 +1,10 @@
2002-10-20 Christopher Faylor <cgf@redhat.com>
+ * cygthread.cc (cygthread::stub): Fix typo.
+ (cygthread::terminate): Don't zero thread handle prior to using it.
+
+2002-10-20 Christopher Faylor <cgf@redhat.com>
+
* sigproc.cc (wait_sig): Remove obsolete sigchld logic.
2002-10-20 Christopher Faylor <cgf@redhat.com>
diff --git a/winsup/cygwin/cygthread.cc b/winsup/cygwin/cygthread.cc
index 76f11390d..e564ad3d0 100644
--- a/winsup/cygwin/cygthread.cc
+++ b/winsup/cygwin/cygthread.cc
@@ -45,7 +45,7 @@ cygthread::stub (VOID *arg)
while (1)
{
if (!info->__name)
- system_printf ("errnoneous thread activation");
+ system_printf ("erroneous thread activation");
else
{
if (!info->func || initialized < 0)
@@ -319,8 +319,9 @@ cygthread::terminate ()
for (unsigned i = 0; i < NTHREADS; i++)
if (threads[i].h)
{
- hthreads[n++] = threads[i].h;
- TerminateThread (threads[i].h, 0);
+ hthreads[n] = threads[i].h;
+ threads[i].h = NULL;
+ TerminateThread (hthreads[n++], 0);
}
if (n)
{