Subj : Re: Windows Suspend/ResumeThread API equivalent for Linux or POSIX? To : comp.programming.threads From : David Schwartz Date : Wed May 11 2005 09:28 pm "Chris Thomasson" <_no_damn_spam_cristom@_no_damn_comcast.net_spam> wrote in message news:pJSdnWBv0tivMB_fRVn-1A@comcast.com... > Microsoft recommends that the thread that calls SuspendThread API not hold > and/or access "any" sync objects: > > http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dllproc/base/suspendthread.asp > > If you can't guarantee this with 100% certainty, then using SuspendThread > is like playing with a lit stick of dynamite. You never can. You never know when a libarary might commandeer your thread and go near a sync object. In order to support Suspend/Resume threads, you must make sure your entire design, from the ground up, is suspension safe. This is a (potentially) huge cost that pthreads decided not to require every implementation to take. DS .