diff --git a/Python/bytecodes.c b/Python/bytecodes.c index 632602ed00bb69..6914d8211ba4ef 100644 --- a/Python/bytecodes.c +++ b/Python/bytecodes.c @@ -1606,7 +1606,7 @@ dummy_func( tstate, PY_MONITORING_EVENT_C_RETURN, frame, next_instr-1, global_super, arg); if (err < 0) { - Py_CLEAR(res); + Py_CLEAR(super); } } } diff --git a/Python/generated_cases.c.h b/Python/generated_cases.c.h index c6efbfeadb2e4b..9c6439ae930706 100644 --- a/Python/generated_cases.c.h +++ b/Python/generated_cases.c.h @@ -2228,7 +2228,7 @@ tstate, PY_MONITORING_EVENT_C_RETURN, frame, next_instr-1, global_super, arg); if (err < 0) { - Py_CLEAR(res); + Py_CLEAR(super); } } }