From: David Butenhof <David.Butenhof@hp.com>
Subject: Re: pthread_kill problem?????
Date: Tue, 14 Oct 2003 09:04:06 -0400 [thread overview]
Message-ID: <3f8bf44d@usenet01.boi.hp.com> (raw)
In-Reply-To: vobbhlb6dhou49@corp.supernews.com
Ron Harter wrote:
> The debugger says that program was executing in the pthread_kill
> function when it got an abort.
a) define "abort". As I've said before, in response to your other
(disconnected) postings and and email, the most likely explanation is a
memory corruption; but you haven't given enough information to be sure.
> We need to be
> able to reliably determine if the communication thread is still available
> for use which is why we are calling pthread_kill(thread_id, 0)
As I believe I've also said, the result of pthread_kill(thread_id,0) is NOT
a reliable indication of whether the "thread is still available for use".
It only indicates whether thread_id contains a value that represents a
thread that currently exists. It does not care whether that ID was
generated for a thread that once existed, terminated, and was reissued to a
new thread. It doesn't care whether the thread is RUNNING or has terminated
and not yet been joined. It only cares whether the ID is valid. This is
probably not what you want if you are trying to determine whether a thread
is "available for use".
--
/--------------------[ David.Butenhof@hp.com ]--------------------\
| Hewlett-Packard Company Tru64 UNIX & VMS Thread Architect |
| My book: http://www.awl.com/cseng/titles/0-201-63392-2/ |
\----[ http://homepage.mac.com/dbutenhof/Threads/Threads.html ]---/
next prev parent reply other threads:[~2003-10-14 13:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-10-07 20:49 pthread_kill problem????? Ron Harter
2003-10-09 13:58 ` Andrew Duane USG
2003-10-09 18:51 ` Ron Harter
2003-10-14 13:04 ` David Butenhof [this message]
2003-10-13 14:49 ` reguera
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox