Hi Samuel, You'll notice that this patch does not take into consideration your recommendation that nameserver host routes be added in __connman_service_append_nameserver. The reason for this is that the gateway is often not known when that function is called. Instead, we must be prepared to add the host routes as soon as the gateway becomes known, which is why I've added new hooks to connman_ipconfig_ops so the service can be notified of this event.
This implementation can be improved. It is inefficient since it triggers update_nameservers to be called more than it really needs to. This could be avoided by replacing the update_nameservers calls in service_new_gateway and service_del_gateway with functions that only remove/add nameserver host routes. (Now that I'm thinking about it, I think this is the right thing to do, but it's late, so maybe I'm not thinking about it correctly.) Let me know what you think. Thanks, Forest -- Forest Bond http://www.alittletooquiet.net http://www.pytagsfs.org
signature.asc
Description: Digital signature
_______________________________________________ connman mailing list [email protected] http://lists.connman.net/listinfo/connman
