Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
TSAN: Fix compiler warning in gc patch
  • Loading branch information
SonicField committed Apr 26, 2024
commit 364d1d9da92e33ce8469387aafadc94f92a7092a
3 changes: 1 addition & 2 deletions Python/gc_free_threading.c
Original file line number Diff line number Diff line change
Expand Up @@ -1048,7 +1048,7 @@ gc_collect_internal(PyInterpreterState *interp, struct collection_state *state,
}

state->gcstate->young.count = 0;
for (size_t i = 1; i <= generation; ++i) {
for (int i = 1; i <= generation; ++i) {
state->gcstate->old[i-1].count = 0;
}

Expand Down Expand Up @@ -1120,7 +1120,6 @@ gc_collect_internal(PyInterpreterState *interp, struct collection_state *state,
static Py_ssize_t
gc_collect_main(PyThreadState *tstate, int generation, _PyGC_Reason reason)
{
int i;
Py_ssize_t m = 0; /* # objects collected */
Py_ssize_t n = 0; /* # unreachable objects that couldn't be collected */
PyTime_t t1 = 0; /* initialize to prevent a compiler warning */
Expand Down