Fix: windows arm7 build

This commit is contained in:
gVisor bot 2021-11-08 21:24:39 +08:00
parent a226cba447
commit f0e12a1285

View File

@ -58,7 +58,7 @@ func bindIfaceToDialer(ifaceName string, dialer *net.Dialer, network string, des
return nil
}
local := 0
local := int64(0)
if dialer.LocalAddr != nil {
_, port, err := net.SplitHostPort(dialer.LocalAddr.String())
if err == nil {
@ -66,7 +66,7 @@ func bindIfaceToDialer(ifaceName string, dialer *net.Dialer, network string, des
}
}
addr, err := lookupLocalAddr(ifaceName, network, destination, local)
addr, err := lookupLocalAddr(ifaceName, network, destination, int(local))
if err != nil {
return err
}
@ -84,7 +84,7 @@ func bindIfaceToListenConfig(ifaceName string, _ *net.ListenConfig, network, add
local, _ := strconv.ParseInt(port, 10, 16)
addr, err := lookupLocalAddr(ifaceName, network, nil, local)
addr, err := lookupLocalAddr(ifaceName, network, nil, int(local))
if err != nil {
return "", err
}