There is a race condition when initializing WorkerThread::m_threadID, because it is stored after the thread is created. This causes assertion failures when checking current thread id. Same problem is present when initializing database threads.
Created attachment 25558 [details] proposed fix
Committed revision 38850.