Skip to content
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

net-utils: consume port range #620

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from
Draft

Conversation

t-nelson
Copy link

@t-nelson t-nelson commented Apr 6, 2024

Problem

#611 attempts to introduce binding sockets with SO_REUSEPORT. this breaks some brittle port allocation logic that assumes bind() with fail for unavailable ports. for those with SO_REUSEPORT set it now succeeds, leading to duplicate allocations.

Summary of Changes

rework bind*in_range helpers from solana_net_utils to work off a shared iterator so ports that are successfully bound are not retried later

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.

1 participant