зеркало из https://github.com/mozilla/pjs.git
Bug 198634: we need to implement PR_DetachThread on the platforms that
don't have a way to detach the foreign threads automatically when they terminate (e.g., OS/2). The patch is contributed by Michael Kaply <mkaply@us.ibm.com>.
This commit is contained in:
Родитель
6e017314e4
Коммит
c4164c36b2
|
@ -1509,6 +1509,18 @@ PR_IMPLEMENT(PRThread*) PR_AttachThread(PRThreadType type,
|
|||
|
||||
PR_IMPLEMENT(void) PR_DetachThread(void)
|
||||
{
|
||||
/*
|
||||
* On IRIX and Windows, foreign threads are detached when
|
||||
* they terminate.
|
||||
*/
|
||||
#if !defined(IRIX) && !defined(WIN32)
|
||||
PRThread *me;
|
||||
if (_pr_initialized) {
|
||||
me = _MD_GET_ATTACHED_THREAD();
|
||||
if ((me != NULL) && (me->flags & _PR_ATTACHED))
|
||||
_PRI_DetachThread();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void _PRI_DetachThread(void)
|
||||
|
|
Загрузка…
Ссылка в новой задаче