mirror of
https://github.com/python/cpython.git
synced 2025-12-04 00:30:19 +00:00
Issue #23524: Finish removing _PyVerify_fd from sources
This commit is contained in:
parent
dee6e252cc
commit
940f33a50f
10 changed files with 27 additions and 258 deletions
|
|
@ -189,16 +189,11 @@ msvcrt_get_osfhandle_impl(PyObject *module, int fd)
|
|||
{
|
||||
intptr_t handle = -1;
|
||||
|
||||
if (!_PyVerify_fd(fd)) {
|
||||
PyErr_SetFromErrno(PyExc_IOError);
|
||||
}
|
||||
else {
|
||||
_Py_BEGIN_SUPPRESS_IPH
|
||||
handle = _get_osfhandle(fd);
|
||||
handle = _get_osfhandle(fd);
|
||||
_Py_END_SUPPRESS_IPH
|
||||
if (handle == -1)
|
||||
PyErr_SetFromErrno(PyExc_IOError);
|
||||
}
|
||||
if (handle == -1)
|
||||
PyErr_SetFromErrno(PyExc_IOError);
|
||||
|
||||
return handle;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue