Re: How to get a thread's status?
- From: "Gary Chanson" <gjchanson@xxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 19 Oct 2005 14:36:15 -0400
<yongzhang81@xxxxxxxxx> wrote in message
news:1129740102.731256.95490@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> Given a handle of a thread.How can I get the thread's status is pending
> or not ?
> Any help will be appreciated.
If by "status is pending" you mean "still executing", when the thread
exits, its handle will be signaled. You can use WaitForSingleObject with a
timeout of zero to test the thread's handle to see if it's signaled.
--
-GJC [MS Windows SDK MVP]
-Software Consultant (Embedded systems and Real Time Controls)
- http://www.mvps.org/ArcaneIncantations/consulting.htm
-gchanson@xxxxxxxx
.
- References:
- How to get a thread's status?
- From: yongzhang81
- How to get a thread's status?
- Prev by Date: Reasonable values for CRITICAL_SECTION spin-count
- Next by Date: RegisterWaitForSingleObject & memory leaks
- Previous by thread: How to get a thread's status?
- Next by thread: Reasonable values for CRITICAL_SECTION spin-count
- Index(es):
Relevant Pages
|