]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-39947: Use _PyInterpreterState_GET_UNSAFE() (GH-18978)
authorVictor Stinner <vstinner@python.org>
Fri, 13 Mar 2020 17:03:56 +0000 (18:03 +0100)
committerGitHub <noreply@github.com>
Fri, 13 Mar 2020 17:03:56 +0000 (18:03 +0100)
commitff4584caca04cb3da0dbd5b1e9bf67e40adf5312
treefedb1e89a042baedb4475e76b12fcf79e2f77837
parent6d674a1bf456945eb758e85c11484a9f1494f2b4
bpo-39947: Use _PyInterpreterState_GET_UNSAFE() (GH-18978)

Replace _PyInterpreterState_Get() function call with
_PyInterpreterState_GET_UNSAFE() macro which is more efficient but
don't check if tstate or interp is NULL.

_Py_GetConfigsAsDict() now uses _PyThreadState_GET().
Modules/_threadmodule.c
Modules/posixmodule.c
Objects/moduleobject.c
Python/codecs.c
Python/dynload_shlib.c
Python/import.c
Python/initconfig.c
Python/pythonrun.c
Python/thread.c