From 46ef667de8405f952fc641ad968e1c1dd3c245d5 Mon Sep 17 00:00:00 2001 From: Beniamino Galvani Date: Mon, 2 May 2016 17:13:06 +0200 Subject: [PATCH] device: remove pending dhcp actions also in IP_DONE state When the IP status is IP_DONE and a DHCP transaction succeeds the 'dhcp4' and 'dhcp6' pending actions must be removed. Without this, a temporary link loss just after the activation would cause a DHCP restart and those actions would remain set, blocking the startup. https://bugzilla.redhat.com/show_bug.cgi?id=1330893 (cherry picked from commit 21ca2cf0f68c79516a885928c33268bb3f12b47e) --- src/devices/nm-device.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c index c56e052288..55002ca892 100644 --- a/src/devices/nm-device.c +++ b/src/devices/nm-device.c @@ -3482,6 +3482,8 @@ dhcp4_lease_change (NMDevice *self, NMIP4Config *config) NULL, NULL, NULL); + + nm_device_remove_pending_action (self, PENDING_ACTION_DHCP4, FALSE); } } @@ -4167,6 +4169,8 @@ dhcp6_lease_change (NMDevice *self) } else { /* Notify dispatcher scripts of new DHCPv6 config */ nm_dispatcher_call (DISPATCHER_ACTION_DHCP6_CHANGE, connection, self, NULL, NULL, NULL); + + nm_device_remove_pending_action (self, PENDING_ACTION_DHCP6, FALSE); } }