summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
Diffstat (limited to 'Python')
-rw-r--r--Python/ceval.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/Python/ceval.c b/Python/ceval.c
index 5fa555e..786adbf 100644
--- a/Python/ceval.c
+++ b/Python/ceval.c
@@ -4410,10 +4410,8 @@ _PyEval_SetCoroutineWrapper(PyObject *wrapper)
{
PyThreadState *tstate = PyThreadState_GET();
- Py_CLEAR(tstate->coroutine_wrapper);
-
Py_XINCREF(wrapper);
- tstate->coroutine_wrapper = wrapper;
+ Py_SETREF(tstate->coroutine_wrapper, wrapper);
}
PyObject *