8000 fix: stop selecting direct connections with too-small MTU by spikecurtis · Pull Request #85 · coder/tailscale · GitHub
[go: up one dir, main page]

Skip to content

fix: stop selecting direct connections with too-small MTU #85

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

Merged
merged 8 commits into from
Jun 10, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
feat: set IP_DONTFRAG on macOS
  • Loading branch information
spikecurtis committed Jun 9, 2025
commit ef3f81d39f70361a38d69c2bcb30cf3f754365a0
6 changes: 3 additions & 3 deletions wgengine/magicsock/magicsock_darwin.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ func trySetPathMTUDiscover(pconn nettype.PacketConn, logf logger.Logf, network s
logf("magicsock: failed to set Path MTU Discover: get syscall conn: %v", err)
}
level := unix.IPPROTO_IP
option := unix.IP_MTU_DISCOVER
option := unix.IP_DONTFRAG
if network == "udp6" {
level = unix.IPPROTO_IPV6
option = unix.IPV6_MTU_DISCOVER
option = unix.IPV6_DONTFRAG
}
err = s.Control(func(fd uintptr) {
err := unix.SetsockoptInt(int(fd), level, option, unix.IP_PMTUDISC_DO)
err := unix.SetsockoptInt(int(fd), level, option, 1)
if err != nil {
logf("magicsock: failed to set Path MTU Discover: SetsockoptInt failed: %v", err)
}
Expand Down
0