diff options
author | Beniamino Galvani <bgalvani@redhat.com> | 2020-07-14 22:52:56 +0200 |
---|---|---|
committer | Beniamino Galvani <bgalvani@redhat.com> | 2020-07-16 09:36:26 +0200 |
commit | 26e97fcd0d4a70e32a484d3bfc57c1802da10554 (patch) | |
tree | b3a966a18c732de145ce33cfb0ac38f4c54e930a | |
parent | e2fba6c4b303afe21272923bc22210e69c1acee6 (diff) | |
download | NetworkManager-bg/rh1856723.tar.gz |
team: perform cleanup immediately when connecting to teamd failsbg/rh1856723
When NM fails to connect to teamd during an activation, it sets the
device state to FAILED. Eventually the device will become DISCONNECTED
and will call the ->deactivate() method that will perform the cleanup
of timers, teamd process and teamdctl instance.
However, in this way, when the device is DISCONNECTED timers are still
armed and can be triggered in the wrong state. Instead, perform the
cleanup immediately on failure.
https://bugzilla.redhat.com/show_bug.cgi?id=1856723
-rw-r--r-- | src/devices/team/nm-device-team.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/devices/team/nm-device-team.c b/src/devices/team/nm-device-team.c index 217c4bdd7c..7ba3034212 100644 --- a/src/devices/team/nm-device-team.c +++ b/src/devices/team/nm-device-team.c @@ -371,6 +371,7 @@ teamd_ready (NMDeviceTeam *self) success = teamd_read_config (self); if (!success) { + teamd_cleanup (self, TRUE); nm_device_state_changed (device, NM_DEVICE_STATE_FAILED, NM_DEVICE_STATE_REASON_TEAMD_CONTROL_FAILED); return; } |