chore: add simple validation for static dialer-proxy config (#2551)

Currently, it can only validate whether a cycle exists in proxies, and cannot determine if it is caused by groups.
This commit is contained in:
sleshep
2026-01-30 20:39:06 +08:00
committed by GitHub
parent d36b024b10
commit 710772f993
3 changed files with 144 additions and 0 deletions

View File

@@ -955,6 +955,12 @@ func parseProxies(cfg *RawConfig) (proxies map[string]C.Proxy, providersMap map[
)
proxies["GLOBAL"] = adapter.NewProxy(global)
}
// validate dialer-proxy references
if err := validateDialerProxies(proxies); err != nil {
return nil, nil, err
}
return proxies, providersMap, nil
}