device: don't necessarily fail the connection when ipv4 DAD fails

Don't necessarily fail the entire connection if a duplicate IPv4
address is detected, but instead look at the may-fail property and at
the outcome of IPv6.

https://bugzilla.redhat.com/show_bug.cgi?id=1508001
(cherry picked from commit 14ad1d0cd1)
This commit is contained in:
Beniamino Galvani 2017-11-02 14:08:55 +01:00
parent e25d6ad0d3
commit e4e6ed5b0a

View file

@ -5395,8 +5395,8 @@ ipv4_manual_method_apply (NMDevice *self, NMIP4Config **configs, gboolean succes
nm_device_activate_schedule_ip4_config_result (self, empty);
g_object_unref (empty);
} else {
nm_device_queue_state (self, NM_DEVICE_STATE_FAILED,
NM_DEVICE_STATE_REASON_CONFIG_FAILED);
nm_device_ip_method_failed (self, AF_INET,
NM_DEVICE_STATE_REASON_IP_CONFIG_UNAVAILABLE);
}
}
@ -5976,8 +5976,8 @@ dhcp4_dad_cb (NMDevice *self, NMIP4Config **configs, gboolean success)
if (success)
nm_device_activate_schedule_ip4_config_result (self, configs[1]);
else {
nm_device_state_changed (self, NM_DEVICE_STATE_FAILED,
NM_DEVICE_STATE_REASON_CONFIG_FAILED);
nm_device_ip_method_failed (self, AF_INET,
NM_DEVICE_STATE_REASON_IP_CONFIG_UNAVAILABLE);
}
}