This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author pitrou
Recipients asvetlov, grahamd, mhammond, ncoghlan, pitrou
Date 2012-08-28.16:47:57
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1346172271.3349.3.camel@localhost.localdomain>
In-reply-to <>
Le mardi 28 août 2012 à 14:12 +0000, Nick Coghlan a écrit :
> old_interp = PyGILState_SwitchInterpreter(target_interp);
> old_gil = PyGILState_Ensure();
> /* Call into Python using target_interp */
> PyGILState_Release(old_gil);
> PyGILState_SwitchInterpreter(old_interp); /* May not be needed in the mod_wsgi case, since it knows it is making the outermost call into the PyGILState_* APIs */

Why wouldn't it be simply written:

old_gil = PyGILState_EnsureEx(target_interp);
/* Call into Python using target_interp */
Date User Action Args
2012-08-28 16:47:57pitrousetrecipients: + pitrou, mhammond, ncoghlan, grahamd, asvetlov
2012-08-28 16:47:57pitroulinkissue15751 messages
2012-08-28 16:47:57pitroucreate