Update system_dialer.go

pull/4932/head
xqzr 2025-07-25 16:27:48 +08:00 committed by GitHub
parent 0799e3619b
commit c639cb5344
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 1 deletions

View File

@ -95,7 +95,9 @@ func (d *DefaultSystemDialer) Dial(ctx context.Context, src net.Address, dest ne
Count: -1,
}
if sockopt != nil && (sockopt.TcpKeepAliveInterval != 0 || sockopt.TcpKeepAliveIdle != 0) {
TCPKeepAliveConfig.Enable = false
TCPKeepAliveConfig = gonet.KeepAliveConfig {
Enable: false
}
}
dialer := &net.Dialer{
Timeout: time.Second * 16,