Kaydet (Commit) aa76d77e authored tarafından Georg Brandl's avatar Georg Brandl

Add a comment about incref'ing w.

üst 3214a01d
......@@ -1617,6 +1617,8 @@ PyEval_EvalFrameEx(PyFrameObject *f, int throwflag)
"lost sys.stdout");
}
if (w != NULL) {
/* w.write() may replace sys.stdout, so we
* have to keep our reference to it */
Py_INCREF(w);
err = PyFile_WriteString("\n", w);
if (err == 0)
......
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