Nick Coghlan added the comment:

It seems to me that the more appropriate change here would be to redefine 
PyState_FindModule as return a *new* ref rather than a borrowed ref and have it 
do the Py_INCREF before returning.

Code using it would then need to add an appropriate Py_DECREF. A reference leak 
is generally a less dangerous bug than an early free.

----------

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

Reply via email to