summaryrefslogtreecommitdiffstats
path: root/Python/pystate.c
diff options
context:
space:
mode:
authorMark Shannon <mark@hotpy.org>2021-06-10 07:46:59 (GMT)
committerGitHub <noreply@github.com>2021-06-10 07:46:59 (GMT)
commit54cb63863f19a7c64d9a3a5fd97bdfc0dd7ab374 (patch)
treedc0e977d4f8e5d8f43e2e231eff206cd7bee9f3a /Python/pystate.c
parente117c0283705943189e6b1aef668a1f68f3f00a4 (diff)
downloadcpython-54cb63863f19a7c64d9a3a5fd97bdfc0dd7ab374.zip
cpython-54cb63863f19a7c64d9a3a5fd97bdfc0dd7ab374.tar.gz
cpython-54cb63863f19a7c64d9a3a5fd97bdfc0dd7ab374.tar.bz2
bpo-44348: Move trace-info to thread-state (GH-26623)
* Move trace-info to thread state. * Correct output for pdb when turning on tracing in middle of line
Diffstat (limited to 'Python/pystate.c')
-rw-r--r--Python/pystate.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/Python/pystate.c b/Python/pystate.c
index 4a3cb24a..a94a615 100644
--- a/Python/pystate.c
+++ b/Python/pystate.c
@@ -688,6 +688,8 @@ new_threadstate(PyInterpreterState *interp, int init)
/* If top points to entry 0, then _PyThreadState_PopLocals will try to pop this chunk */
tstate->datastack_top = &tstate->datastack_chunk->data[1];
tstate->datastack_limit = (PyObject **)(((char *)tstate->datastack_chunk) + DATA_STACK_CHUNK_SIZE);
+ /* Mark trace_info as uninitialized */
+ tstate->trace_info.code = NULL;
if (init) {
_PyThreadState_Init(tstate);