summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSeonah Moon <seonah1.moon@samsung.com>2017-10-31 13:35:57 +0900
committertaesub kim <taesub.kim@samsung.com>2017-10-31 14:25:12 +0900
commit8810cd173465b340be47b57f43ef6ceb836912e4 (patch)
treeda556ff467615a0634555f2fbb2d3d216aa4b4cd
parent4ccbf7bcbc9d1df402e7262b040771950712f82b (diff)
downloadconnman-8810cd173465b340be47b57f43ef6ceb836912e4.tar.gz
connman-8810cd173465b340be47b57f43ef6ceb836912e4.tar.bz2
connman-8810cd173465b340be47b57f43ef6ceb836912e4.zip
Fixed gateway issue for ipv6
Change-Id: I27a77e6a39fb11095446c95fb9765da5e7e156f6 Signed-off-by: Taesub Kim <taesub.kim@samsung.com>
-rwxr-xr-xsrc/dhcpv6.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/dhcpv6.c b/src/dhcpv6.c
index bf4da3e7..85714e91 100755
--- a/src/dhcpv6.c
+++ b/src/dhcpv6.c
@@ -685,6 +685,9 @@ static void set_address(int ifindex, struct connman_ipconfig *ipconfig,
/* Is this prefix part of the subnet we are suppose to use? */
prefix_len = check_ipv6_addr_prefix(prefixes, address);
+#if defined TIZEN_EXT
+ char *gateway = g_strdup(__connman_ipconfig_get_gateway(ipconfig));
+#endif
__connman_ipconfig_address_remove(ipconfig);
__connman_ipconfig_set_local(ipconfig, address);
__connman_ipconfig_set_prefixlen(ipconfig, prefix_len);
@@ -692,6 +695,11 @@ static void set_address(int ifindex, struct connman_ipconfig *ipconfig,
DBG("new address %s/%d", address, prefix_len);
__connman_ipconfig_set_dhcp_address(ipconfig, address);
+#if defined TIZEN_EXT
+ DBG("Set gateway %s", gateway);
+ __connman_ipconfig_set_gateway(ipconfig, gateway);
+ g_free(gateway);
+#endif
__connman_service_save(
__connman_service_lookup_from_index(ifindex));
}