[issue1758146] Crash in PyObject_Malloc
Adam Olsen
report at bugs.python.org
Wed Jul 9 07:26:04 CEST 2008
Adam Olsen <rhamph at gmail.com> added the comment:
It's only checking that the original tstate *for the current thread* and
the new tstate have a different subinterpreter. A subinterpreter can
have multiple tstates, so long as they're all in different threads.
The documentation is referring specifically to the PyGILState_Ensure and
PyGILState_Release functions. Calling these says "I want a tstate, and
I don't know if I had one already". The problem is that, with
subinterpreters, you may not get a tstate with the subinterpreter you
want. subinterpreter references saved in globals may lead to obscure
crashes or other errors - some of these have been fixed over the years,
but I doubt they all have.
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue1758146>
_______________________________________
More information about the Python-bugs-list
mailing list