mirror of
https://github.com/netbirdio/gvisor.git
synced 2026-05-22 17:12:49 -07:00
{Set,Get} SO_LINGER on all endpoints.
SO_LINGER is a socket level option and should be stored on all endpoints even though it is used to linger only for TCP endpoints. PiperOrigin-RevId: 332369252
This commit is contained in:
committed by
gVisor bot
parent
c0b74be54c
commit
d34bda0273
@@ -1185,7 +1185,7 @@ func getSockOptSocket(t *kernel.Task, s socket.SocketOps, ep commonEndpoint, fam
|
||||
var v tcpip.LingerOption
|
||||
var linger linux.Linger
|
||||
if err := ep.GetSockOpt(&v); err != nil {
|
||||
return &linger, nil
|
||||
return nil, syserr.TranslateNetstackError(err)
|
||||
}
|
||||
|
||||
if v.Enabled {
|
||||
|
||||
Reference in New Issue
Block a user