mirror of
https://github.com/XTLS/Xray-core.git
synced 2026-10-05 21:38:12 +03:00
TUN inbound: Start on Windows when IPv6 is disabled system-wide (#6874)
https://github.com/XTLS/Xray-core/pull/6874#issuecomment-5989986544
This commit is contained in:
@@ -178,6 +178,11 @@ startOver:
|
||||
}
|
||||
ipif, err := t.luid.IPInterface(family)
|
||||
if err != nil {
|
||||
// With IPv6 disabled system-wide (DisabledComponents), the adapter has no
|
||||
// IPv6 interface at all. Skip the family unless the config asks for it.
|
||||
if err == windows.ERROR_NOT_FOUND && family == windows.AF_INET6 && !address6 && !route6 {
|
||||
continue
|
||||
}
|
||||
return err
|
||||
}
|
||||
ipif.RouterDiscoveryBehavior = winipcfg.RouterDiscoveryDisabled
|
||||
|
||||
Reference in New Issue
Block a user