Skip to content

multi: hold timeout values in 'int' instead of 'long' - #22564

Closed
bagder wants to merge 2 commits into
masterfrom
bagder/multi-timeout-int
Closed

bagder wants to merge 2 commits into
masterfrom
bagder/multi-timeout-int

Conversation

@bagder

@bagder bagder commented Aug 12, 2026

Copy link
Copy Markdown
Member

Since this code needs to work (identically) on systems with 32 bit longs anyway, this might just as well always use 32 bit to save space and make the code work the same everywhere.

bagder added 2 commits August 12, 2026 23:38
Since this code needs to work (identically) on systems with 32 bit longs
anyway, this might just as well always use 32 bit to save space and make
the code work the same everywhere.
@bagder
bagder marked this pull request as ready for review August 12, 2026 21:52
@bagder
bagder requested a balanced review from Copilot August 12, 2026 21:52

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Uses int for internal multi-handle timeout values, ensuring consistent 32-bit behavior across platforms.

Changes:

  • Converts internal timeout storage and calculations from long to int.
  • Clamps oversized timeout differences to INT_MAX.
  • Updates tracing format specifiers and public API conversion.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
lib/multihandle.h Stores the last callback timeout as an int.
lib/multi.c Converts, clamps, and reports internal timeouts as int.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@bagder bagder closed this in 3089e7e Aug 12, 2026
@bagder
bagder deleted the bagder/multi-timeout-int branch August 12, 2026 22:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants