Skip to content

fix(run): alternate DNS stub port allocation - #490

Draft
LukeMathWalker wants to merge 2 commits into
mainfrom
fix/windows-dns-stub-port-allocation
Draft

fix(run): alternate DNS stub port allocation#490
LukeMathWalker wants to merge 2 commits into
mainfrom
fix/windows-dns-stub-port-allocation

Conversation

@LukeMathWalker

Copy link
Copy Markdown
Contributor

Why

Windows maintains independent TCP and UDP excluded-port ranges. The host DNS stub could repeatedly choose TCP ports that UDP rejects with WSAEACCES, causing otherwise unrelated Windows CI jobs to fail, as seen in this run.

What Changed

  • Alternate between UDP-selected and TCP-selected ephemeral port candidates.
  • Keep the first socket open while binding the matching port for the other protocol.
  • Increase the bounded search to 64 total candidates.
  • Preserve errors from both allocation directions in the startup failure.

Risks / Notes

The failure depends on Windows-specific excluded-port configuration and cannot be reproduced in the Linux development environment. The existing cross-platform tests exercise startup, shutdown, loopback binding, and DNS responses over both UDP and TCP; Windows CI provides the platform-specific regression coverage.

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