prefix|scope .= 6

This commit is contained in:
Doug MacEachern committed 2009-07-25 08:09:53 -07:00
1 parent 8411da271e
commit 0da8e9d95f
7 files changed
+18 -18

No files matched your search

+6 -6
View File
@@ -2656,22 +2656,22 @@ int sigar_net_interface_ipv6_config_get(sigar_t *sigar, const char *name,
sigar_net_address6_set(ifconfig->address6, addr);
ifconfig->prefix_length = sigar_in6_prefixlen(ifa->ifa_netmask);
ifconfig->prefix6_length = sigar_in6_prefixlen(ifa->ifa_netmask);
if (IN6_IS_ADDR_LINKLOCAL(addr)) {
ifconfig->scope = SIGAR_IPV6_ADDR_LINKLOCAL;
ifconfig->scope6 = SIGAR_IPV6_ADDR_LINKLOCAL;
}
else if (IN6_IS_ADDR_SITELOCAL(addr)) {
ifconfig->scope = SIGAR_IPV6_ADDR_SITELOCAL;
ifconfig->scope6 = SIGAR_IPV6_ADDR_SITELOCAL;
}
else if (IN6_IS_ADDR_V4COMPAT(addr)) {
ifconfig->scope = SIGAR_IPV6_ADDR_COMPATv4;
ifconfig->scope6 = SIGAR_IPV6_ADDR_COMPATv4;
}
else if (IN6_IS_ADDR_LOOPBACK(addr)) {
ifconfig->scope = SIGAR_IPV6_ADDR_LOOPBACK;
ifconfig->scope6 = SIGAR_IPV6_ADDR_LOOPBACK;
}
else {
ifconfig->scope = SIGAR_IPV6_ADDR_ANY;
ifconfig->scope6 = SIGAR_IPV6_ADDR_ANY;
}
}
+2 -2
View File
@@ -2124,8 +2124,8 @@ int sigar_net_interface_ipv6_config_get(sigar_t *sigar, const char *name,
addr6[i] = (unsigned char)hex2int(ptr, 2);
}
ifconfig->prefix_length = prefix;
ifconfig->scope = scope;
ifconfig->prefix6_length = prefix;
ifconfig->scope6 = scope;
}
return status;