diff options
author | Samuel Ortiz <sameo@linux.intel.com> | 2010-12-21 12:50:31 +0100 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2010-12-21 12:50:31 +0100 |
commit | 1339c2b9108c95d65b1eb2ada00c64be76008e5d (patch) | |
tree | 9a7841780455d6d695ebe5fef59c43ee0039838b /src/connection.c | |
parent | 28bedc10b1d4cc6d3cf4602211a36b5c48414937 (diff) | |
download | connman-1339c2b9108c95d65b1eb2ada00c64be76008e5d.tar.gz connman-1339c2b9108c95d65b1eb2ada00c64be76008e5d.tar.bz2 connman-1339c2b9108c95d65b1eb2ada00c64be76008e5d.zip |
connection: Add gateway host routes for non NULL gateways
Diffstat (limited to 'src/connection.c')
-rw-r--r-- | src/connection.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/connection.c b/src/connection.c index bac700f1..cb0ca223 100644 --- a/src/connection.c +++ b/src/connection.c @@ -320,9 +320,12 @@ static int connection_probe(struct connman_element *element) service = __connman_element_get_service(element); - connman_inet_add_ipv6_host_route(element->index, + if (new_gateway->ipv6_gateway) + connman_inet_add_ipv6_host_route(element->index, new_gateway->ipv6_gateway, NULL); - connman_inet_add_host_route(element->index, + + if (g_strcmp0(new_gateway->ipv4_gateway, "0.0.0.0")) + connman_inet_add_host_route(element->index, new_gateway->ipv4_gateway, NULL); __connman_service_nameserver_add_routes(service, new_gateway->ipv4_gateway); |