summaryrefslogtreecommitdiffhomepage
path: root/pkg/tcpip/transport/tcpconntrack
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2020-07-13 19:03:18 +0000
committergVisor bot <gvisor-bot@google.com>2020-07-13 19:03:18 +0000
commit0a49098e2b456f23af79341530d79f9128b58bb5 (patch)
treedde9d942d1dae331e62bdde25f067286c3b8a390 /pkg/tcpip/transport/tcpconntrack
parent4e931be12f70e320c7d750fba1c3a3c6b008ddb6 (diff)
parent43c209f48e0aa9024705583cc6f0fafa7d6380ca (diff)
Merge release-20200622.1-97-g43c209f48 (automated)
Diffstat (limited to 'pkg/tcpip/transport/tcpconntrack')
-rw-r--r--pkg/tcpip/transport/tcpconntrack/tcp_conntrack.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/pkg/tcpip/transport/tcpconntrack/tcp_conntrack.go b/pkg/tcpip/transport/tcpconntrack/tcp_conntrack.go
index 12bc1b5b5..558b06df0 100644
--- a/pkg/tcpip/transport/tcpconntrack/tcp_conntrack.go
+++ b/pkg/tcpip/transport/tcpconntrack/tcp_conntrack.go
@@ -106,6 +106,11 @@ func (t *TCB) UpdateStateOutbound(tcp header.TCP) Result {
return st
}
+// State returns the current state of the TCB.
+func (t *TCB) State() Result {
+ return t.state
+}
+
// IsAlive returns true as long as the connection is established(Alive)
// or connecting state.
func (t *TCB) IsAlive() bool {