refactor: tcp dial (#412)

Non-concurrent support to try to connect in turn

fix: serial dual stack dial
This commit is contained in:
Skyxim
2023-02-26 11:24:49 +08:00
committed by wwqgtxx
parent 5e7d644efd
commit 97e14337e3
2 changed files with 170 additions and 249 deletions

View File

@ -331,11 +331,7 @@ func updateTunnels(tunnels []LC.Tunnel) {
func updateGeneral(general *config.General) {
tunnel.SetMode(general.Mode)
tunnel.SetFindProcessMode(general.FindProcessMode)
dialer.DisableIPv6 = !general.IPv6
if !dialer.DisableIPv6 {
log.Infoln("Use IPv6")
}
resolver.DisableIPv6 = dialer.DisableIPv6
resolver.DisableIPv6 =!general.IPv6
if general.TCPConcurrent {
dialer.SetDial(general.TCPConcurrent)