summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBeniamino Galvani <bgalvani@redhat.com>2016-05-10 16:34:50 +0200
committerBeniamino Galvani <bgalvani@redhat.com>2016-05-10 17:56:02 +0200
commit0b66eb298e1d6ac1ef516635e7055a6c819b4e09 (patch)
treef1e3964019e236082b2c12696aa89eef4d5b4b43
parent702b74c9f73d7b6b1c4c082c531eb1fb46ac7d83 (diff)
downloadNetworkManager-0b66eb298e1d6ac1ef516635e7055a6c819b4e09.tar.gz
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
-rw-r--r--src/devices/nm-device.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c
index 8e15e1e63e..9283ff45c3 100644
--- a/src/devices/nm-device.c
+++ b/src/devices/nm-device.c
@@ -4545,6 +4545,8 @@ dhcp4_lease_change (NMDevice *self, NMIP4Config *config)
NULL,
NULL);
+ nm_device_remove_pending_action (self, PENDING_ACTION_DHCP4, FALSE);
+
return TRUE;
}
@@ -5297,6 +5299,8 @@ dhcp6_lease_change (NMDevice *self)
nm_device_get_applied_connection (self),
self, NULL, NULL, NULL);
+ nm_device_remove_pending_action (self, PENDING_ACTION_DHCP6, FALSE);
+
return TRUE;
}