mirror of
https://github.com/python/cpython.git
synced 2025-11-01 10:45:30 +00:00
execfile should call PyErr_SetFromErrnoWithFilename instead of
simply PyErr_SetFromErrno This closes bug 599163.
This commit is contained in:
parent
80a04a4894
commit
4c0134248c
1 changed files with 1 additions and 1 deletions
|
|
@ -553,7 +553,7 @@ builtin_execfile(PyObject *self, PyObject *args)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!exists) {
|
if (!exists) {
|
||||||
PyErr_SetFromErrno(PyExc_IOError);
|
PyErr_SetFromErrnoWithFilename(PyExc_IOError, filename);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
cf.cf_flags = 0;
|
cf.cf_flags = 0;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue