summaryrefslogtreecommitdiffhomepage
path: root/pkg/tcpip/transport/tcp/endpoint.go
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2020-01-15 21:35:57 +0000
committergVisor bot <gvisor-bot@google.com>2020-01-15 21:35:57 +0000
commit0f82a58822a207d9fb067f55e41bb0e278b5c8ef (patch)
tree5991ceac3bd518595cac69850fae61b24e1940ad /pkg/tcpip/transport/tcp/endpoint.go
parentaaf481b4f1184b8a3f98a4179b59b96eb09d3de8 (diff)
parent275ac8ce1debf89a22eb1150df3bf9ba7a0bc9ba (diff)
Merge release-20191213.0-119-g275ac8c (automated)
Diffstat (limited to 'pkg/tcpip/transport/tcp/endpoint.go')
-rw-r--r--pkg/tcpip/transport/tcp/endpoint.go7
1 files changed, 1 insertions, 6 deletions
diff --git a/pkg/tcpip/transport/tcp/endpoint.go b/pkg/tcpip/transport/tcp/endpoint.go
index 1799c6e10..4797f11d1 100644
--- a/pkg/tcpip/transport/tcp/endpoint.go
+++ b/pkg/tcpip/transport/tcp/endpoint.go
@@ -2019,18 +2019,13 @@ func (e *endpoint) Shutdown(flags tcpip.ShutdownFlags) *tcpip.Error {
// If we're fully closed and we have unread data we need to abort
// the connection with a RST.
if (e.shutdownFlags&tcpip.ShutdownWrite) != 0 && rcvBufUsed > 0 {
- // Move the socket to error state immediately.
- // This is done redundantly because in case of
- // save/restore on a Shutdown/Close() the socket
- // state needs to indicate the error otherwise
- // save file will show the socket in established
- // state even though snd/rcv are closed.
e.mu.Unlock()
// Try to send an active reset immediately if the
// work mutex is available.
if e.workMu.TryLock() {
e.mu.Lock()
e.resetConnectionLocked(tcpip.ErrConnectionAborted)
+ e.notifyProtocolGoroutine(notifyTickleWorker)
e.mu.Unlock()
e.workMu.Unlock()
} else {