ping: Fix on android

This commit is contained in:
世界
2025-08-24 10:47:15 +08:00
parent 86d96064d5
commit dd18aa2b86
2 changed files with 3 additions and 3 deletions

View File

@@ -47,7 +47,7 @@ func connect(privileged bool, controlFunc control.Func, destination netip.Addr)
return nil, E.Cause(err, "connect()")
}
if destination.Is4() && runtime.GOOS == "linux" {
if destination.Is4() && (runtime.GOOS == "linux" || runtime.GOOS == "android") {
//err = unix.SetsockoptInt(fd, unix.IPPROTO_IP, unix.IP_RECVTOS, 1)
//if err != nil {
// return nil, err