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 0563ec9 commit 3dab9e0Copy full SHA for 3dab9e0
1 file changed
Modules/itertoolsmodule.c
@@ -1028,8 +1028,10 @@ tee_copy_impl(teeobject *to)
1028
if (newto == NULL) {
1029
return NULL;
1030
}
1031
+ Py_BEGIN_CRITICAL_SECTION(to);
1032
newto->dataobj = (teedataobject *)Py_NewRef(to->dataobj);
1033
newto->index = to->index;
1034
+ Py_END_CRITICAL_SECTION();
1035
newto->weakreflist = NULL;
1036
newto->state = to->state;
1037
PyObject_GC_Track(newto);
0 commit comments