mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1024732 - Don't set PJS helper thread state to TERMINATED on error when starting the helper threads. (r=nmatsakis)
This commit is contained in:
parent
e1d1268cfc
commit
c581483075
@ -141,18 +141,11 @@ ThreadPoolWorker::start()
|
||||
// Set state to active now, *before* the thread starts:
|
||||
state_ = ACTIVE;
|
||||
|
||||
if (!PR_CreateThread(PR_USER_THREAD,
|
||||
HelperThreadMain, this,
|
||||
PR_PRIORITY_NORMAL, PR_GLOBAL_THREAD,
|
||||
PR_UNJOINABLE_THREAD,
|
||||
WORKER_THREAD_STACK_SIZE))
|
||||
{
|
||||
// If the thread failed to start, call it TERMINATED.
|
||||
state_ = TERMINATED;
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
return PR_CreateThread(PR_USER_THREAD,
|
||||
HelperThreadMain, this,
|
||||
PR_PRIORITY_NORMAL, PR_GLOBAL_THREAD,
|
||||
PR_UNJOINABLE_THREAD,
|
||||
WORKER_THREAD_STACK_SIZE);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user