We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 702ea95 commit 24ea805Copy full SHA for 24ea805
Python/tracemalloc.c
@@ -866,6 +866,9 @@ _PyTraceMalloc_Stop(void)
866
goto done;
867
}
868
869
+ /* stop tracing Python memory allocations */
870
+ _Py_atomic_store_int_relaxed(&tracemalloc_config.tracing, 0);
871
+
872
/* unregister the hook on memory allocators */
873
PyMem_SetAllocator(PYMEM_DOMAIN_RAW, &allocators.raw);
874
PyMem_SetAllocator(PYMEM_DOMAIN_MEM, &allocators.mem);
@@ -879,9 +882,6 @@ _PyTraceMalloc_Stop(void)
879
882
880
883
(void)PyRefTracer_SetTracer(NULL, NULL);
881
884
- /* stop tracing Python memory allocations */
- _Py_atomic_store_int_relaxed(&tracemalloc_config.tracing, 0);
-
885
done:
886
TABLES_UNLOCK();
887
0 commit comments