Erik Bray added the comment:

Ah, I wasn't thinking clearly toward the bottom of my last message.  I see now 
that after a fork, _PyGILState_Reinit calls PyThread_delete_key followed by a 
new PyThread_create_key--in the current version of my patch that would result 
in putting the autoTLSkey at the end of the linked list, which is no good.  
That could be worked around, but...

Ed's version looks good to me.  I had the same idea as an alternative, though 
was a little concerned with the possibility that the array could grow too 
large.  But as I wrote in my last message that would be an extreme case.  And 
regardless his version will at least maintain constant time, so +1.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue25658>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to