diff options
author | Eric Snow <ericsnowcurrently@gmail.com> | 2022-01-13 23:33:40 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-13 23:33:40 (GMT) |
commit | b8ddf7e794e5316981016d6d014862e3c4ce149a (patch) | |
tree | b351b3bda79db119c6ba679649d3180fc7811fc1 /Python | |
parent | bc02eac9d2cb36faffc5027b7ce09e6dd0922a7f (diff) | |
download | cpython-b8ddf7e794e5316981016d6d014862e3c4ce149a.zip cpython-b8ddf7e794e5316981016d6d014862e3c4ce149a.tar.gz cpython-b8ddf7e794e5316981016d6d014862e3c4ce149a.tar.bz2 |
Statically initialize _PyRuntimeState fields. (gh-30588)
https://bugs.python.org/issue45953
Diffstat (limited to 'Python')
-rw-r--r-- | Python/pystate.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/Python/pystate.c b/Python/pystate.c index e617585..50b3621 100644 --- a/Python/pystate.c +++ b/Python/pystate.c @@ -111,17 +111,7 @@ init_runtime(_PyRuntimeState *runtime, PyPreConfig_InitPythonConfig(&runtime->preconfig); - runtime->gilstate.check_enabled = 1; - - /* A TSS key must be initialized with Py_tss_NEEDS_INIT - in accordance with the specification. */ - Py_tss_t initial = Py_tss_NEEDS_INIT; - runtime->gilstate.autoTSSkey = initial; - runtime->interpreters.mutex = interpreters_mutex; - // This prevents interpreters from getting created - // until _PyInterpreterState_Enable() is called. - runtime->interpreters.next_id = -1; runtime->xidregistry.mutex = xidregistry_mutex; |