[issue1856] shutdown (exit) can hang or segfault with daemon threads running

Adam Olsen report at bugs.python.org
Thu Jan 17 23:35:36 CET 2008


Adam Olsen added the comment:

I'm not sure I understand you, Gregory.  Are arguing in favour of adding
extra logic to the GIL code, or against it?

I'm attaching a patch that has non-main thread exit, and it seems to fix
the test case.  It doesn't fix the PyGILState_Ensure problems though.

Also note that PyThread_exit_thread() was completely broken, becoming a
no-op once threading was initialized, and even before then it would exit
the process rather than just the thread.  I've fixed it for pthreads,
but not for any of the other platforms.

Added file: http://bugs.python.org/file9199/python-trunk-issue1856-threadexit.diff

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1856>
__________________________________


More information about the Python-bugs-list mailing list