diff options
author | Jukka Rissanen <jukka.rissanen@linux.intel.com> | 2012-06-06 14:37:32 +0300 |
---|---|---|
committer | Patrik Flykt <patrik.flykt@linux.intel.com> | 2012-06-11 13:30:18 +0300 |
commit | 9ccbb57dedc7c64bb92e2042981b455c0f1d9243 (patch) | |
tree | 780692bd6c7fea090508c2fab080bf72334ff7de /src | |
parent | b75f76746851e045bbe46abc7ec9daf61cb5a136 (diff) | |
download | connman-9ccbb57dedc7c64bb92e2042981b455c0f1d9243.tar.gz connman-9ccbb57dedc7c64bb92e2042981b455c0f1d9243.tar.bz2 connman-9ccbb57dedc7c64bb92e2042981b455c0f1d9243.zip |
ipconfig: Set IPv6 privacy default value from kernel default
Use value set in the kernel as the initial IPv6 privacy
setting. This also allows distros to set the privacy value
without needing to tweak connman.
Diffstat (limited to 'src')
-rw-r--r-- | src/ipconfig.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/ipconfig.c b/src/ipconfig.c index 3b85827f..b401c236 100644 --- a/src/ipconfig.c +++ b/src/ipconfig.c @@ -1245,6 +1245,7 @@ void __connman_ipconfig_set_prefixlen(struct connman_ipconfig *ipconfig, unsigne static struct connman_ipconfig *create_ipv6config(int index) { struct connman_ipconfig *ipv6config; + struct connman_ipdevice *ipdevice; DBG("index %d", index); @@ -1258,7 +1259,10 @@ static struct connman_ipconfig *create_ipv6config(int index) ipv6config->enabled = FALSE; ipv6config->type = CONNMAN_IPCONFIG_TYPE_IPV6; ipv6config->method = CONNMAN_IPCONFIG_METHOD_AUTO; - ipv6config->ipv6_privacy_config = 0; + + ipdevice = g_hash_table_lookup(ipdevice_hash, GINT_TO_POINTER(index)); + if (ipdevice != NULL) + ipv6config->ipv6_privacy_config = ipdevice->ipv6_privacy; ipv6config->address = connman_ipaddress_alloc(AF_INET6); if (ipv6config->address == NULL) { |