Skip to content

bpo-41710: Fix PY_TIMEOUT_MAX on Windows#28673

Merged
vstinner merged 2 commits intopython:mainfrom
vstinner:timeout_ms_max
Oct 1, 2021
Merged

bpo-41710: Fix PY_TIMEOUT_MAX on Windows#28673
vstinner merged 2 commits intopython:mainfrom
vstinner:timeout_ms_max

Conversation

@vstinner
Copy link
Member

@vstinner vstinner commented Oct 1, 2021

WaitForSingleObject() accepts timeout in milliseconds in the range
[0; 0xFFFFFFFE] (DWORD type). INFINITE value (0xFFFFFFFF) means no
timeout. 0xFFFFFFFE milliseconds is around 49.7 days.

PY_TIMEOUT_MAX is (0xFFFFFFFE * 1000) milliseconds on Windows, around
49.7 days.

Partially revert commit 37b8294.

https://bugs.python.org/issue41710

WaitForSingleObject() accepts timeout in milliseconds in the range
[0; 0xFFFFFFFE] (DWORD type). INFINITE value (0xFFFFFFFF) means no
timeout. 0xFFFFFFFE milliseconds is around 49.7 days.

PY_TIMEOUT_MAX is (0xFFFFFFFE * 1000) milliseconds on Windows, around
49.7 days.

Partially revert commit 37b8294.
@vstinner
Copy link
Member Author

vstinner commented Oct 1, 2021

See #28672 (comment) for details about the timeout limit.

@vstinner vstinner merged commit 98d2827 into python:main Oct 1, 2021
@vstinner vstinner deleted the timeout_ms_max branch October 1, 2021 11:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants