Fixed deadlock in Process::WorkerThreadProc.