mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-08-10 13:20:33 +02:00
ignore network check.
This commit is contained in:
@@ -7,6 +7,7 @@ import (
|
|||||||
"net"
|
"net"
|
||||||
"os"
|
"os"
|
||||||
"os/signal"
|
"os/signal"
|
||||||
|
"runtime"
|
||||||
"sync"
|
"sync"
|
||||||
"sync/atomic"
|
"sync/atomic"
|
||||||
"syscall"
|
"syscall"
|
||||||
@@ -89,6 +90,15 @@ func supportListenIPv6Local() bool {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func probeStack() {
|
func probeStack() {
|
||||||
|
// On Android, skip network probing to avoid blocking the VPN service initialization.
|
||||||
|
// Android VPN services manage their own network state and will fail gracefully
|
||||||
|
// if network is unavailable when actual DNS queries are made.
|
||||||
|
if runtime.GOOS == "android" {
|
||||||
|
hasNetworkUp = true
|
||||||
|
canListenIPv6Local = false
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
ctx, cancel := context.WithCancel(context.Background())
|
ctx, cancel := context.WithCancel(context.Background())
|
||||||
defer cancel()
|
defer cancel()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user