Kaydet (Commit) 5e78f4da authored tarafından Victor Stinner's avatar Victor Stinner

Issue #22762: Fix _Py_DisplaySourceLine(), clear the exception if

PyFile_GetLine() failed. Patch written by Xavier de Gaye.
üst 2acbae80
......@@ -322,6 +322,7 @@ _Py_DisplaySourceLine(PyObject *f, PyObject *filename, int lineno, int indent)
Py_XDECREF(lineobj);
lineobj = PyFile_GetLine(fob, -1);
if (!lineobj) {
PyErr_Clear();
err = -1;
break;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment