mirror of
https://github.com/tailscale/tailscale.git
synced 2025-04-21 06:01:42 +00:00
net/interfaces: assume the network's up on js/wasm
Updates #3157 Change-Id: If4acd33598ad5e8ef7fb5960964c9ac32bc8f68b Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
parent
9310713bfb
commit
8efc306e4f
@ -414,6 +414,9 @@ func (s *State) HasPAC() bool { return s != nil && s.PAC != "" }
|
|||||||
|
|
||||||
// AnyInterfaceUp reports whether any interface seems like it has Internet access.
|
// AnyInterfaceUp reports whether any interface seems like it has Internet access.
|
||||||
func (s *State) AnyInterfaceUp() bool {
|
func (s *State) AnyInterfaceUp() bool {
|
||||||
|
if runtime.GOOS == "js" {
|
||||||
|
return true
|
||||||
|
}
|
||||||
return s != nil && (s.HaveV4 || s.HaveV6)
|
return s != nil && (s.HaveV4 || s.HaveV6)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user