diff options
author | Thomas Haller <thaller@redhat.com> | 2022-10-27 21:43:02 +0200 |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2022-10-28 17:54:15 +0200 |
commit | 0f0468b208b8e1c45d57be9b1d0b1bd2d27d5d51 (patch) | |
tree | d149c957813189529dbd5794e2e6b9152d490e8f | |
parent | 6414b016a7440f9e10fc90fcb4f71dad8890cb87 (diff) | |
download | NetworkManager-0f0468b208b8e1c45d57be9b1d0b1bd2d27d5d51.tar.gz |
libnm: fix _nm_setting_property_compare_fcn_default() for "to_dbus_only_in_manager_process"
property_to_dbus() gets called for two reasons. Once from
_nm_setting_to_dbus(). In that case, we want to honor
to_dbus_only_in_manager_process().
It gets also called from _nm_setting_property_compare_fcn_default(),
with ignore_flags set. In that case, we don't want to ignore the property
as the hook really wants to compare them.
Fixes: c8392018ca19 ('libnm: refactor to-dbus on the client skipping to serialize legacy properties')
-rw-r--r-- | src/libnm-core-impl/nm-setting.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libnm-core-impl/nm-setting.c b/src/libnm-core-impl/nm-setting.c index ebb3cb5e71..f6c969ba72 100644 --- a/src/libnm-core-impl/nm-setting.c +++ b/src/libnm-core-impl/nm-setting.c @@ -1783,7 +1783,8 @@ property_to_dbus(const NMSettInfoSetting *sett_info, || NM_FLAGS_HAS(property_info->param_spec->flags, G_PARAM_WRITABLE) || property_info->property_type == &nm_sett_info_propert_type_setting_name); - if (property_info->to_dbus_only_in_manager_process && !_nm_utils_is_manager_process) + if (!ignore_flags && property_info->to_dbus_only_in_manager_process + && !_nm_utils_is_manager_process) return NULL; if (property_info->param_spec && !ignore_flags |