[issue6643] Throw away more radioactive locks that could be held across a fork in threading.py
Nadeem Vawda
report at bugs.python.org
Tue Jan 4 17:31:45 CET 2011
Nadeem Vawda <nadeem.vawda at gmail.com> added the comment:
r87710 introduces an AttributeError in test_thread's TestForkInThread test case. If os.fork() is called from a thread created by the _thread module, threading._after_fork() will get a _DummyThread (with no _block attribute) as the current thread.
I've attached a patch that checks whether the thread has a _block attribute before trying to reinitialize it.
----------
nosy: +nvawda
Added file: http://bugs.python.org/file20259/test_thread.diff
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue6643>
_______________________________________
More information about the Python-bugs-list
mailing list