mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Issue #20320: select.select() and select.kqueue.control() now round the timeout
aways from zero, instead of rounding towards zero. It should make test_asyncio more reliable, especially test_timeout_rounding() test.
This commit is contained in:
parent
23f628de4a
commit
3c1b379ebd
10 changed files with 179 additions and 62 deletions
|
@ -799,7 +799,8 @@ signal_sigtimedwait(PyObject *self, PyObject *args)
|
|||
&signals, &timeout))
|
||||
return NULL;
|
||||
|
||||
if (_PyTime_ObjectToTimespec(timeout, &tv_sec, &tv_nsec) == -1)
|
||||
if (_PyTime_ObjectToTimespec(timeout, &tv_sec, &tv_nsec,
|
||||
_PyTime_ROUND_DOWN) == -1)
|
||||
return NULL;
|
||||
buf.tv_sec = tv_sec;
|
||||
buf.tv_nsec = tv_nsec;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue