google / gvisor

Application Kernel for Containers

Home Page:https://gvisor.dev

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Shutdown on connecting socket has no effect

arthurpi opened this issue · comments

In gvisor, when a connecting (SYN_SENT) socket is shutdown(2) (SHUT_RD and/or SHUT_WR), nothing happens, and shutdown(2) returns ENOTCONN.

On linux, shutdown(2) succeeds and the socket locally enters an error state (POLLHUP | POLLERR | POLLOUT is observed). (no RST/FIN is sent to the listener's host)