Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
@TimonPost reports encountering this consistently on WSL, and observed it at least once in our CI at https://github.com/quinn-rs/quinn/actions/runs/1630318713, manifesting as a cmsg_len of 20 rather than the expected 17. It was observed for the echo_dualstack and echo_v4 tests, but apparently not for echo_v6. Looking around the kernel source, I'm not sure how this is possible; the only origin seems to be https://elixir.bootlin.com/linux/latest/source/net/ipv4/ip_sockglue.c#L73, which has a very clearly hardcoded size of 1.
Our current behavior should be correct in release builds on little-endian systems, and harmlessly broken on big-endian systems. Still, I'd like to be able to account for why this is necessary, if nothing else so we can narrow down and perhaps someday remove the mitigation.