[issue33625] Disable GIL on getpwnam and getpwuid

Serhiy Storchaka report at bugs.python.org
Thu May 24 07:30:55 EDT 2018


Serhiy Storchaka <storchaka+cpython at gmail.com> added the comment:

Functions getpwnam() and getpwuid() are not reentrant. This is not a problem if their use is guarded with GIL and extensions don't call them directly. But if release GIL, we should use reentrant getpwnam_r() and getpwuid_r() instead. There may be an open issue for this, but I can't find it now.

If getpwnam_r() and getpwuid_r() are not available (are there such modern platforms?) we should use getpwnam() and getpwuid() without releasing GIL.

----------
nosy: +serhiy.storchaka

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue33625>
_______________________________________


More information about the Python-bugs-list mailing list