bpo-31857: Make the behavior of USE_STACKCHECK deterministic (#4098)


diff --git a/Python/pystate.c b/Python/pystate.c
index d85d604..82ebf4d 100644
--- a/Python/pystate.c
+++ b/Python/pystate.c
@@ -245,6 +245,7 @@
         tstate->recursion_depth = 0;
         tstate->overflowed = 0;
         tstate->recursion_critical = 0;
+        tstate->stackcheck_counter = 0;
         tstate->tracing = 0;
         tstate->use_tracing = 0;
         tstate->gilstate_counter = 0;