Don't keep the Python thread-lock - this prevents secondary threads from

starting.  Not part of the build.


git-svn-id: svn://10.0.0.236/trunk@150791 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
mhammond%skippinet.com.au
2003-12-30 23:15:33 +00:00
parent 32352ec42a
commit 8c9e42bffb

View File

@@ -202,7 +202,10 @@ extern "C" NS_EXPORT nsresult NSGetModule(nsIComponentManager *servMgr,
PyThreadState_Delete(threadStateSave);
}
#else
PyGILState_Release(state);
// If we initialized Python, then we will also have acquired the thread
// lock. In that case, we want to leave it unlocked, so other threads
// are free to run, even if they aren't running Python code.
PyGILState_Release(bDidInitPython ? PyGILState_UNLOCKED : state);
#endif
NS_TIMELINE_STOP_TIMER("PyXPCOM: Python threadstate setup");