getting a thread state in c++/windows

Idov picture Idov · Jan 5, 2011 · Viewed 9.3k times · Source


There must be a function that gets the current status of a thread in the system because
there is this application: http://www.softwareverify.com/cpp/thread-status-monitor/index.html

It must be using some sort of API function or something... How can I get a thread state myself in C++/Windows?
thanks :)

(this is my last question for today. I promise :))

Answer

Nickolay Olshevsky picture Nickolay Olshevsky · Jan 5, 2011

That's done via Toolhelp library, check information at MSDN : http://msdn.microsoft.com/en-us/library/ms686780%28v=VS.85%29.aspx