http: disable keepalive when KeepAliveInterval is negative (#7158)
Co-authored-by: Matt Holt <mholt@users.noreply.github.com>
This commit is contained in:
parent
5125fbed41
commit
fdf610850b
1 changed files with 1 additions and 1 deletions
|
|
@ -533,7 +533,7 @@ func (app *App) Start() error {
|
|||
// create the listener for this socket
|
||||
lnAny, err := listenAddr.Listen(app.ctx, portOffset, net.ListenConfig{
|
||||
KeepAliveConfig: net.KeepAliveConfig{
|
||||
Enable: srv.KeepAliveInterval != 0,
|
||||
Enable: srv.KeepAliveInterval >= 0,
|
||||
Interval: time.Duration(srv.KeepAliveInterval),
|
||||
},
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue