配置对象都加上了取地址符 &

This commit is contained in:
CN-JS-HuiBai
2026-04-15 00:06:39 +08:00
parent be4d0c3ac0
commit ee7300435a

View File

@@ -274,14 +274,14 @@ func (s *Service) setupNode() error {
}, },
} }
} }
inboundOptions = vlessOptions inboundOptions = &vlessOptions
case "vmess": case "vmess":
vmessOptions := option.VMessInboundOptions{ vmessOptions := option.VMessInboundOptions{
ListenOptions: option.ListenOptions{ ListenOptions: option.ListenOptions{
ListenPort: uint16(inner.Port), ListenPort: uint16(inner.Port),
}, },
} }
inboundOptions = vmessOptions inboundOptions = &vmessOptions
case "shadowsocks": case "shadowsocks":
ssOptions := option.ShadowsocksInboundOptions{ ssOptions := option.ShadowsocksInboundOptions{
ListenOptions: option.ListenOptions{ ListenOptions: option.ListenOptions{
@@ -290,14 +290,14 @@ func (s *Service) setupNode() error {
Method: inner.Cipher, Method: inner.Cipher,
Password: inner.ServerKey, Password: inner.ServerKey,
} }
inboundOptions = ssOptions inboundOptions = &ssOptions
case "trojan": case "trojan":
trojanOptions := option.TrojanInboundOptions{ trojanOptions := option.TrojanInboundOptions{
ListenOptions: option.ListenOptions{ ListenOptions: option.ListenOptions{
ListenPort: uint16(inner.Port), ListenPort: uint16(inner.Port),
}, },
} }
inboundOptions = trojanOptions inboundOptions = &trojanOptions
default: default:
return fmt.Errorf("unsupported protocol: %s", protocol) return fmt.Errorf("unsupported protocol: %s", protocol)
} }