Kaydet (Commit) 7c0b0cc9 authored tarafından Charles-François Natali's avatar Charles-François Natali

Issue #11051: Reduce the number of syscalls per import.

üst 3be637e6
......@@ -1944,8 +1944,7 @@ find_module_path_list(PyObject *fullname, PyObject *name,
if (Py_VerboseFlag > 1)
PySys_FormatStderr("# trying %R\n", filename);
if (_Py_stat(filename, &statbuf) == 0 && /* it exists */
S_ISDIR(statbuf.st_mode)) /* it's a directory */
if (_Py_stat(filename, &statbuf) != 0 || S_ISDIR(statbuf.st_mode))
{
Py_DECREF(filename);
continue;
......
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