From: Yu A Wang Date: Fri, 12 Aug 2011 06:43:26 +0000 (-0400) Subject: service: Fix wrong DNS server ip after VPN connection X-Git-Tag: 0.77~21 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9e83f367842b77a6e0475668f18a89a0740c7cde;p=platform%2Fupstream%2Fconnman.git service: Fix wrong DNS server ip after VPN connection We need to call default_changed function for ONLINE state after profile changed, else get_default function will return the previous service, this will lead to we have wrong DNS after VPN connection --- diff --git a/src/service.c b/src/service.c index 81c4f60..f5312b5 100644 --- a/src/service.c +++ b/src/service.c @@ -3535,8 +3535,6 @@ static int __connman_service_indicate_state(struct connman_service *service) } connman_timeserver_sync(); - - default_changed(); } if (new_state == CONNMAN_SERVICE_STATE_IDLE) { @@ -3629,6 +3627,9 @@ static int __connman_service_indicate_state(struct connman_service *service) __connman_profile_changed(FALSE); + if (new_state == CONNMAN_SERVICE_STATE_ONLINE) + default_changed(); + return 0; }