fix: tunnel's inboundTFO missing

This commit is contained in:
gVisor bot 2023-02-24 14:19:50 +08:00
parent 262ce7325c
commit df28a353b9
2 changed files with 3 additions and 2 deletions

View file

@ -148,7 +148,6 @@ func updateListeners(general *config.General, listeners map[string]C.InboundList
dialer.DefaultInterface.Store(general.Interface) dialer.DefaultInterface.Store(general.Interface)
} }
inbound.SetTfo(general.InboundTfo)
allowLan := general.AllowLan allowLan := general.AllowLan
listener.SetAllowLan(allowLan) listener.SetAllowLan(allowLan)
@ -341,6 +340,8 @@ func updateGeneral(general *config.General) {
log.Infoln("Use tcp concurrent") log.Infoln("Use tcp concurrent")
} }
inbound.SetTfo(general.InboundTfo)
adapter.UnifiedDelay.Store(general.UnifiedDelay) adapter.UnifiedDelay.Store(general.UnifiedDelay)
// Avoid reload configuration clean the value, causing traffic loops // Avoid reload configuration clean the value, causing traffic loops
if listener.GetTunConf().Enable && listener.GetTunConf().AutoDetectInterface { if listener.GetTunConf().Enable && listener.GetTunConf().AutoDetectInterface {

View file

@ -41,7 +41,7 @@ func (l *Listener) handleTCP(conn net.Conn, in chan<- C.ConnContext, additions .
} }
func New(addr, target, proxy string, in chan<- C.ConnContext, additions ...inbound.Addition) (*Listener, error) { func New(addr, target, proxy string, in chan<- C.ConnContext, additions ...inbound.Addition) (*Listener, error) {
l, err := net.Listen("tcp", addr) l, err := inbound.Listen("tcp", addr)
if err != nil { if err != nil {
return nil, err return nil, err
} }