1
0
mirror of https://github.com/gluster/glusterd2.git synced 2026-02-05 12:45:38 +01:00

Support ipv6-only hosts

This commit is contained in:
Sheena Artrip
2018-02-02 15:21:24 -08:00
committed by Sheena Artrip
parent 624c6bce5b
commit c9beeb8441

View File

@@ -323,6 +323,9 @@ func GetLocalIP() (string, error) {
if ipnet.IP.To4() != nil {
return ipnet.IP.String(), nil
}
if ipnet.IP.To16() != nil {
return ipnet.IP.String(), nil
}
}
}
return "", errors.ErrIPAddressNotFound