From: Daniel Wagner Date: Mon, 19 Mar 2012 12:50:40 +0000 (+0100) Subject: ipconfig: Disable IPv6 for new interfaces X-Git-Tag: 2.0_alpha~504 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4ce90440a70abce7de5377776e942ff14e7152f9;p=framework%2Fconnectivity%2Fconnman.git ipconfig: Disable IPv6 for new interfaces We don't have yet an ipconfig for this interface, that means the service.c does not yet know this interface. In order to be able to get into sync we disable IPv6 auto connection at this point. If the service state machine decides to connect, it will enable it again. --- diff --git a/src/ipconfig.c b/src/ipconfig.c index 399e492..af5666d 100644 --- a/src/ipconfig.c +++ b/src/ipconfig.c @@ -550,6 +550,13 @@ static void __connman_ipconfig_lower_up(struct connman_ipdevice *ipdevice) { DBG("ipconfig ipv4 %p ipv6 %p", ipdevice->config_ipv4, ipdevice->config_ipv6); + + if (ipdevice->config_ipv6 != NULL && + ipdevice->config_ipv6->enabled == TRUE) + return; + + set_ipv6_state(ipdevice->ifname, FALSE); + ipdevice->ipv6_enabled = FALSE; } static void __connman_ipconfig_lower_down(struct connman_ipdevice *ipdevice)