-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
check for WSAEMSGSIZE errors when receiving UDP packets on Windows #3982
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3982 +/- ##
==========================================
+ Coverage 82.92% 82.99% +0.07%
==========================================
Files 146 146
Lines 14707 14801 +94
==========================================
+ Hits 12195 12284 +89
- Misses 2022 2030 +8
+ Partials 490 487 -3
|
2e4abe9
to
e38398e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For windows this looks okay.
What happens on linux here? https://man7.org/linux/man-pages/man3/recvfrom.3p.html says
If a message is too long to fit in the supplied
buffer, and MSG_PEEK is not set in the flags argument, the excess
bytes shall be discarded.
Is this fine?
You might have to do handling for macOS since we merged #3946
This does indeed fix the problem, according to my tests.
No changes should be necessary- the DF bit on outgoing datagrams shouldn't affect recvfrom(). It would affect things if we were using recvmsg() instead, and able to receive |
@thepaul yes, there's no real change involved here. My comment was related to changes in That commit changed the build flags on |
Oh yes, I did read that change- sorry I wasn't clear! That change seems to amount to "set the DF bit on outgoing packets", and my claim is that that won't affect what is received with |
This PR splits |
e38398e
to
a5ca166
Compare
I see. This PR was based on an older commit, that's why CI succeeded on |
Fixes #3956. @thepaul, could you give this patch a try?