Fix: set mitm outbound

This commit is contained in:
yaling888 2022-05-16 01:23:14 +08:00
parent 8b3e42bf19
commit 72b9b829e9

View File

@ -101,7 +101,11 @@ func SetMode(m TunnelMode) {
// SetMitmOutbound set the MITM outbound // SetMitmOutbound set the MITM outbound
func SetMitmOutbound(outbound C.ProxyAdapter) { func SetMitmOutbound(outbound C.ProxyAdapter) {
mitmProxy = A.NewProxy(outbound) if outbound != nil {
mitmProxy = A.NewProxy(outbound)
} else {
mitmProxy = nil
}
} }
// Rewrites return all rewrites // Rewrites return all rewrites