Discussion:
how can I get an Handle to a thread from htread ID?
(too old to reply)
Francesco
2005-02-13 04:49:43 UTC
Permalink
Hi,

I 'm using CreateToolhelp32Snapshot() on PPC2003 to obtain a list of all
running thread.
It give me the threadID but when I use GetThreadTimes() I need a valid
Handle.
Using "GetThreadTimes((HANDLE)th32.th32ThreadID......) it returns the
"invalid handle"
error for all system threads but it works only for my application thread.
How can I obtain a valid handle from system thread id?

thanks,

Francesco
<ctacke/>
2005-02-13 14:38:14 UTC
Permalink
This really has no bearing on Platform Builder - I think crossposting is
good, but only when the groups are relevant.

-Chris
Post by Francesco
Hi,
I 'm using CreateToolhelp32Snapshot() on PPC2003 to obtain a list of all
running thread.
It give me the threadID but when I use GetThreadTimes() I need a valid
Handle.
Using "GetThreadTimes((HANDLE)th32.th32ThreadID......) it returns the
"invalid handle"
error for all system threads but it works only for my application thread.
How can I obtain a valid handle from system thread id?
thanks,
Francesco
Loading...