8000 bpo-41710: Fix PY_TIMEOUT_MAX on Windows by vstinner · Pull Request #28673 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

bpo-41710: Fix PY_TIMEOUT_MAX on Windows #28673

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 1, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix test
  • Loading branch information
vstinner committed Oct 1, 2021
commit a3a9da09057118994b3f7962f8be835ff64419ba
2 changes: 1 addition & 1 deletion Python/thread_nt.h
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ PyThread_acquire_lock_timed(PyThread_type_lock aLock,
if (microseconds % 1000 > 0) {
milliseconds++;
}
if (milliseconds > TIMEOUT_MS_MAX) {
if (milliseconds > (PY_TIMEOUT_T)TIMEOUT_MS_MAX) {
// bpo-41710: PyThread_acquire_lock_timed() cannot report timeout
// overflow to the caller, so clamp the timeout to
// [0, TIMEOUT_MS_MAX] milliseconds.
Expand Down
0