fixed threaded loading

This commit is contained in:
roberto@debian32
2011-06-24 19:42:01 +02:00
parent 789e333736
commit 2246d30bbe
7 changed files with 21 additions and 26 deletions
+2 -2
View File
@@ -4,7 +4,7 @@ extern struct uwsgi_server uwsgi;
extern struct uwsgi_python up;
void gil_real_get() {
uwsgi_log("LOCK %d\n", uwsgi.mywid);
//uwsgi_log("LOCK %d\n", uwsgi.mywid);
#ifndef PYTHREE
PyEval_AcquireLock();
PyThreadState_Swap((PyThreadState *) pthread_getspecific(up.upt_gil_key));
@@ -14,7 +14,7 @@ void gil_real_get() {
}
void gil_real_release() {
uwsgi_log("UNLOCK %d\n", uwsgi.mywid);
//uwsgi_log("UNLOCK %d\n", uwsgi.mywid);
#ifndef PYTHREE
pthread_setspecific(up.upt_gil_key, (void *) PyThreadState_Swap(NULL));
PyEval_ReleaseLock();