Thanks to visit codestin.com Credit goes to github.com
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 4aa8679 commit 04d09ebCopy full SHA for 04d09eb
1 file changed
Modules/_io/textio.c
@@ -2435,14 +2435,10 @@ textiowrapper_tell(textio *self, PyObject *args)
2435
if (saved_state) {
2436
PyObject *type, *value, *traceback;
2437
PyErr_Fetch(&type, &value, &traceback);
2438
-
2439
res = _PyObject_CallMethodId(self->decoder, &PyId_setstate, "(O)", saved_state);
+ _PyErr_ChainExceptions(type, value, traceback);
2440
Py_DECREF(saved_state);
2441
- if (res == NULL)
2442
- return NULL;
2443
- Py_DECREF(res);
2444
2445
- PyErr_Restore(type, value, traceback);
+ Py_XDECREF(res);
2446
}
2447
return NULL;
2448
0 commit comments