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

Restore set/get of SO_RCVBUF socket option in frame receiver UDP RX thread #272

Merged
merged 1 commit into from
Mar 19, 2021

Conversation

timcnicholls
Copy link
Contributor

This PR addresses #271 and fixes the regression in setting the receive buffer size on the UDP socket in the receive thread of the frame receiver.

The readback/reporting of the buffer size now also includes a divide by two to account for the kernel allocation behaviour, so that the true buffer size available is reported in matches the requested size.

@timcnicholls timcnicholls added this to the 1.6.0 milestone Mar 19, 2021
Copy link
Collaborator

@ulrikpedersen ulrikpedersen left a comment

Choose a reason for hiding this comment

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

That is indeed the change we've discussed on slack and in meeting yesterday 👍

@GDYendell
Copy link
Collaborator

Is it possible to use both of these options?

@timcnicholls
Copy link
Contributor Author

I'm not sure what you mean @GDYendell ?

@GDYendell
Copy link
Collaborator

GDYendell commented Mar 25, 2021

Sorry. Is it possible to keep SO_REUSEADDR enabled rather than replacing it? Or are they not compatible?

@timcnicholls
Copy link
Contributor Author

timcnicholls commented Mar 25, 2021

SO_REUSEADDR has no utility on a UDP socket unless you're using broadcast/multicast, to allow multiple processes to bind to the same port. The TIME_WAIT issue only affects closing TCP sockets.

@GDYendell
Copy link
Collaborator

Ahh. Yes OK, I didn't spot that this is only in the UDP child class.

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.

4 participants