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

Clear errno before calling opendir() and readdir().

üst 377be11e
...@@ -1845,6 +1845,7 @@ posix_listdir(PyObject *self, PyObject *args) ...@@ -1845,6 +1845,7 @@ posix_listdir(PyObject *self, PyObject *args)
struct dirent *ep; struct dirent *ep;
int arg_is_unicode = 1; int arg_is_unicode = 1;
errno = 0;
if (!PyArg_ParseTuple(args, "U:listdir", &v)) { if (!PyArg_ParseTuple(args, "U:listdir", &v)) {
arg_is_unicode = 0; arg_is_unicode = 0;
PyErr_Clear(); PyErr_Clear();
......
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