actually store netmask

This commit is contained in:
Christian Ulrich 2020-07-25 12:00:21 +02:00
parent 4f64b7be53
commit 73a22c0816
No known key found for this signature in database
GPG Key ID: 8241BE099775A097
1 changed files with 1 additions and 1 deletions

View File

@ -37,7 +37,7 @@ proc fromIpAddress*(address: IpAddress): NetworkInterface =
it.ifa_addr.sa_family.cint == AF_INET6) and
$address == it.ifa_addr.getAddrString():
result.ipAddress = address
result.netMask = parseIpAddress(it.ifa_addr.getAddrString())
result.netMask = parseIpAddress(it.ifa_netmask.getAddrString())
result.name = $it.ifa_name
result.index = if_nametoindex(result.name).cint
result.flags = it.ifa_flags