diff --git a/hub/executor/executor.go b/hub/executor/executor.go index d5ca4afb8..8cb8358fb 100644 --- a/hub/executor/executor.go +++ b/hub/executor/executor.go @@ -134,7 +134,7 @@ func GetGeneral() *config.General { RedirPort: ports.RedirPort, TProxyPort: ports.TProxyPort, MixedPort: ports.MixedPort, - Tun: listener.LastTunConf, + Tun: listener.GetTunConf(), TuicServer: listener.GetTuicConf(), ShadowSocksConfig: ports.ShadowSocksConfig, VmessConfig: ports.VmessConfig, diff --git a/listener/listener.go b/listener/listener.go index 7b513fa7f..a340d3a2d 100644 --- a/listener/listener.go +++ b/listener/listener.go @@ -84,9 +84,7 @@ type Ports struct { func GetTunConf() LC.Tun { if tunLister == nil { - return LC.Tun{ - Enable: false, - } + return LastTunConf } return tunLister.Config() }