diff options
| author | Brad Fitzpatrick <bradfitz@tailscale.com> | 2025-04-01 04:01:00 -0700 |
|---|---|---|
| committer | Brad Fitzpatrick <brad@danga.com> | 2025-04-02 07:36:04 -0700 |
| commit | e3282c163231ad9d0bfdf6d43fecfb8ebe154c2c (patch) | |
| tree | 4372ba284be8ac6408f661b63182566a81a91e16 | |
| parent | 60847128df6f30d12312f55a7a06d03c0363996e (diff) | |
| download | tailscale-e3282c163231ad9d0bfdf6d43fecfb8ebe154c2c.tar.xz tailscale-e3282c163231ad9d0bfdf6d43fecfb8ebe154c2c.zip | |
wgengine/magicsock: avoid some log spam on Plan 9
Updates #5794
Change-Id: I12e8417ebd553f9951690c388fbe42228f8c9097
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
| -rw-r--r-- | wgengine/magicsock/magicsock.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/wgengine/magicsock/magicsock.go b/wgengine/magicsock/magicsock.go index e8e966582..313f9e315 100644 --- a/wgengine/magicsock/magicsock.go +++ b/wgengine/magicsock/magicsock.go @@ -3018,6 +3018,10 @@ func (c *Conn) DebugForcePreferDERP(n int) { // portableTrySetSocketBuffer sets SO_SNDBUF and SO_RECVBUF on pconn to socketBufferSize, // logging an error if it occurs. func portableTrySetSocketBuffer(pconn nettype.PacketConn, logf logger.Logf) { + if runtime.GOOS == "plan9" { + // Not supported. Don't try. Avoid logspam. + return + } if c, ok := pconn.(*net.UDPConn); ok { // Attempt to increase the buffer size, and allow failures. if err := c.SetReadBuffer(socketBufferSize); err != nil { |
