network: convert SO_RCVTIMEO between guest and host units #1351
No reviewers
Labels
No labels
bug
documentation
duplicate
enhancement
GPU
GUI
help wanted
question
Shaders
Video
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/KytyPS5--KytyPS5!1351
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1351/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@HamsterCL on GitHub · 2026-10-10 02:41 UTC · original
HamsterCL:fix/net-recv-timeout-units→main· +30 −3 · 1 files · 1 commits · closed without mergingThe guest passes
SO_RCVTIMEO(0x1006) as an int in milliseconds, but the option was not recognised: on Windows the raw guest option number was passed straight to the host. This maps it to the host option and converts the value inSetsockoptandGetsockopt, as is already done forSO_SNDTIMEO(a DWORD in ms on Windows, a timeval elsewhere).Setsockoptnow rejects any option size other thansizeof(int).Split out of the closed #1329 as a one-file change. Built and ran the ctest suite locally on Windows (clang-cl). All pass except image_transfer_layout, which also fails on current main without this change.
@coderabbitai[bot] on GitHub · 2026-10-10 02:44 UTC · original
No actionable comments were generated in the recent review. 🎉
ℹ️ Recent review info
⚙️ Run configuration
75f154d2-1602-46f3-891f-8e43f8fd2e6a📥 Commits
Reviewing files that changed from the base of the PR and between
679be25c37and1c6f597316.📒 Files selected for processing (1)
src/libs/network.cppIncluded review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 1 remain after this review.
📝 Walkthrough
Walkthrough
The network library maps guest socket option
0x1006toSO_RCVTIMEO.Getsockoptconverts host receive-timeout values to guest milliseconds and caps the result atINT_MAX.Setsockoptvalidates the guest value size, clamps negative milliseconds to zero, and converts the value to the host timeout format.Suggested reviewers:
nmzikPriority: ⬇️ Low
Change: Bug fix
Merge Risk: ⚪ Minimal · up to
1c6f5The receive-timeout change converts values between guest milliseconds and the platform’s host format. No actionable merge-blocking risk remains.
Pre-merge checks |
4 |
1
❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
#1329is closed and supplies historical context only. Therefore, no linked-issue coding requirements apply to this pull request.Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
❤️ Share
Comment
@coderabbitai helpto get the list of available commands.Pull request closed