diff options
author | 2020-11-18 08:01:48 -0800 | |
---|---|---|
committer | 2020-11-18 08:01:48 -0800 | |
commit | 994c68f586441cee755508e9357e6e03e2b7a887 (patch) | |
tree | 28312823d8d46acaa8f72a7c1e7dc7f3728f8f41 /Python | |
parent | [3.9] bpo-41561: skip test_min_max_version_mismatch (GH-22308) (GH-23363) (diff) | |
download | cpython-994c68f586441cee755508e9357e6e03e2b7a887.tar.gz cpython-994c68f586441cee755508e9357e6e03e2b7a887.tar.bz2 cpython-994c68f586441cee755508e9357e6e03e2b7a887.zip |
bpo-40998: Address compiler warnings found by ubsan (GH-20929)
Signed-off-by: Christian Heimes <christian@python.org>
Automerge-Triggered-By: GH:tiran
(cherry picked from commit 07f2adedf0940b06d136208ec386d69b7d2d5b43)
Co-authored-by: Christian Heimes <christian@python.org>
Diffstat (limited to 'Python')
-rw-r--r-- | Python/pylifecycle.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/Python/pylifecycle.c b/Python/pylifecycle.c index 5c50d4d290f..60f091cbbea 100644 --- a/Python/pylifecycle.c +++ b/Python/pylifecycle.c @@ -1353,7 +1353,6 @@ Py_FinalizeEx(void) /* Get current thread state and interpreter pointer */ PyThreadState *tstate = _PyRuntimeState_GetThreadState(runtime); - PyInterpreterState *interp = tstate->interp; // Wrap up existing "threading"-module-created, non-daemon threads. wait_for_thread_shutdown(tstate); @@ -1376,13 +1375,13 @@ Py_FinalizeEx(void) /* Copy the core config, PyInterpreterState_Delete() free the core config memory */ #ifdef Py_REF_DEBUG - int show_ref_count = interp->config.show_ref_count; + int show_ref_count = tstate->interp->config.show_ref_count; #endif #ifdef Py_TRACE_REFS - int dump_refs = interp->config.dump_refs; + int dump_refs = tstate->interp->config.dump_refs; #endif #ifdef WITH_PYMALLOC - int malloc_stats = interp->config.malloc_stats; + int malloc_stats = tstate->interp->config.malloc_stats; #endif /* Remaining daemon threads will automatically exit |