mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-07-23 11:14:29 +00:00
2008-03-13 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerPolicy.c - (update_routing_and_dns): never set the default route through an IPv4LL addressed device git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3449 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
This commit is contained in:
parent
6cfaab9c0c
commit
5fa56a8ba4
|
@ -1,3 +1,9 @@
|
|||
2008-03-13 Dan Williams <dcbw@redhat.com>
|
||||
|
||||
* src/NetworkManagerPolicy.c
|
||||
- (update_routing_and_dns): never set the default route through an
|
||||
IPv4LL addressed device
|
||||
|
||||
2008-03-13 Dan Williams <dcbw@redhat.com>
|
||||
|
||||
* NetworkManagerUtils.c
|
||||
|
|
|
@ -121,12 +121,25 @@ update_routing_and_dns (NMPolicy *policy, gboolean force_update)
|
|||
devices = nm_manager_get_devices (policy->manager);
|
||||
for (iter = devices; iter; iter = g_slist_next (iter)) {
|
||||
NMDevice *dev = NM_DEVICE (iter->data);
|
||||
NMActRequest *req;
|
||||
NMConnection *connection;
|
||||
NMSettingIP4Config *s_ip4;
|
||||
guint32 prio;
|
||||
|
||||
if ( (nm_device_get_state (dev) != NM_DEVICE_STATE_ACTIVATED)
|
||||
|| !nm_device_get_ip4_config (dev))
|
||||
continue;
|
||||
|
||||
req = nm_device_get_act_request (dev);
|
||||
g_assert (req);
|
||||
connection = nm_act_request_get_connection (req);
|
||||
g_assert (connection);
|
||||
|
||||
/* Never set the default route through an IPv4LL-addressed device */
|
||||
s_ip4 = (NMSettingIP4Config *) nm_connection_get_setting (connection, NM_TYPE_SETTING_IP4_CONFIG);
|
||||
if (s_ip4 && !strcmp (s_ip4->method, NM_SETTING_IP4_CONFIG_METHOD_AUTOIP))
|
||||
continue;
|
||||
|
||||
prio = get_device_priority (dev);
|
||||
if (prio > best_prio) {
|
||||
best = dev;
|
||||
|
|
Loading…
Reference in a new issue