diff options
author | Bhasker Hariharan <bhaskerh@google.com> | 2019-06-12 13:34:47 -0700 |
---|---|---|
committer | Shentubot <shentubot@google.com> | 2019-06-12 13:35:50 -0700 |
commit | 70578806e8d3e01fae2249b3e602cd5b05d378a0 (patch) | |
tree | 6909e9f6103e23c43d753d10d9ee424670e8c8cd /pkg/tcpip/tcpip.go | |
parent | bb849bad296f372670c2d2cf97424f74cf750ce2 (diff) |
Add support for TCP_CONGESTION socket option.
This CL also cleans up the error returned for setting congestion
control which was incorrectly returning EINVAL instead of ENOENT.
PiperOrigin-RevId: 252889093
Diffstat (limited to 'pkg/tcpip/tcpip.go')
-rw-r--r-- | pkg/tcpip/tcpip.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/pkg/tcpip/tcpip.go b/pkg/tcpip/tcpip.go index 85ef014d0..04c776205 100644 --- a/pkg/tcpip/tcpip.go +++ b/pkg/tcpip/tcpip.go @@ -472,6 +472,14 @@ type KeepaliveIntervalOption time.Duration // closed. type KeepaliveCountOption int +// CongestionControlOption is used by SetSockOpt/GetSockOpt to set/get +// the current congestion control algorithm. +type CongestionControlOption string + +// AvailableCongestionControlOption is used to query the supported congestion +// control algorithms. +type AvailableCongestionControlOption string + // MulticastTTLOption is used by SetSockOpt/GetSockOpt to control the default // TTL value for multicast messages. The default is 1. type MulticastTTLOption uint8 |