summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2022-08-01 20:53:02 +0200
committerThomas Haller <thaller@redhat.com>2022-08-11 18:10:12 +0200
commit6eaee2b13f012213376dc9d91fa28f197a07c2ce (patch)
tree7dd5af94210f8e5016d71683e330f09289b83c54
parentdced08e3b045d72d5b6c5cdd1e9b5de552d2dfea (diff)
downloadNetworkManager-6eaee2b13f012213376dc9d91fa28f197a07c2ce.tar.gz
device: fix reapply for lldp/mdns/llmnr/dns-over-tls settings
When only one of those connection.{lldp,mdns,llmnr,dns-over-tls} settings changes, we still need to do a full restart of the IP configuration to reapply the changes. Fixes: 58287cbcc0c8 ('core: rework IP configuration in NetworkManager using layer 3 configuration') (cherry picked from commit f4b128c63bff29ee096ef6e09f49e6c0c7744d18)
-rw-r--r--src/core/devices/nm-device.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/core/devices/nm-device.c b/src/core/devices/nm-device.c
index d5c7de64ac..6b854517e5 100644
--- a/src/core/devices/nm-device.c
+++ b/src/core/devices/nm-device.c
@@ -12695,6 +12695,16 @@ check_and_reapply_connection(NMDevice *self,
if (nm_g_hash_table_lookup(diffs, NM_SETTING_IP6_CONFIG_SETTING_NAME))
priv->ip_data_6.do_reapply = TRUE;
+ if (nm_g_hash_table_contains_any(
+ nm_g_hash_table_lookup(diffs, NM_SETTING_CONNECTION_SETTING_NAME),
+ NM_SETTING_CONNECTION_LLDP,
+ NM_SETTING_CONNECTION_MDNS,
+ NM_SETTING_CONNECTION_LLMNR,
+ NM_SETTING_CONNECTION_DNS_OVER_TLS)) {
+ priv->ip_data_4.do_reapply = TRUE;
+ priv->ip_data_6.do_reapply = TRUE;
+ }
+
nm_device_activate_schedule_stage3_ip_config(self, FALSE);
_routing_rules_sync(self, NM_TERNARY_TRUE);