Skip to content

Clamp suspend linger and wakeup deadline - #250

Merged
kasperisager merged 2 commits into
holepunchto:mainfrom
ozanhonamlioglu:fix-suspend-wakeup-clamp
Oct 13, 2026
Merged

kasperisager merged 2 commits into
holepunchto:mainfrom
ozanhonamlioglu:fix-suspend-wakeup-clamp

Conversation

@ozanhonamlioglu

Copy link
Copy Markdown
Contributor

x & 0xffffffff converts to a signed 32-bit integer, so values of 2^31 or
more turned negative or wrapped to small numbers, and Infinity became 0.
A negative deadline left the wakeup timer never firing. Clamp
to 0x7fffffff, the largest value the native side can take, in both
Bare and Bare.Thread.

@ozanhonamlioglu
ozanhonamlioglu requested a review from a team October 13, 2026 13:54
@ozanhonamlioglu
ozanhonamlioglu marked this pull request as draft October 13, 2026 13:54
@ozanhonamlioglu
ozanhonamlioglu marked this pull request as ready for review October 13, 2026 14:28
@kasperisager
kasperisager merged commit d8dfe7b into holepunchto:main Oct 13, 2026
15 checks passed
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.

2 participants