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: 58287cbcc0 ('core: rework IP configuration in NetworkManager using layer 3 configuration')
(cherry picked from commit f4b128c63b)
(cherry picked from commit 6eaee2b13f)
This commit is contained in:
Thomas Haller 2022-08-01 20:53:02 +02:00
parent 1999fa9650
commit 7d8e43df94
No known key found for this signature in database
GPG key ID: 29C2366E4DFC5728

View file

@ -12691,6 +12691,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);