mirror of
https://github.com/python/cpython.git
synced 2025-11-02 03:01:58 +00:00
merge 3.3
This commit is contained in:
commit
9f30abd393
3 changed files with 13 additions and 3 deletions
|
|
@ -422,7 +422,7 @@ signal_set_wakeup_fd(PyObject *self, PyObject *args)
|
|||
return NULL;
|
||||
}
|
||||
#endif
|
||||
if (fd != -1 && fstat(fd, &buf) != 0) {
|
||||
if (fd != -1 && (!_PyVerify_fd(fd) || fstat(fd, &buf) != 0)) {
|
||||
PyErr_SetString(PyExc_ValueError, "invalid fd");
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue