diff options
| author | Michael Biebl <biebl@debian.org> | 2019-02-26 19:02:28 +0100 |
|---|---|---|
| committer | Michael Biebl <biebl@debian.org> | 2019-02-26 19:02:28 +0100 |
| commit | 439c9d76f576ae28c73571d444c59d9e95e5ad11 (patch) | |
| tree | 7591e0b43641131fc049d6d7a0bd19e9e4964a40 /libnm-core/nm-setting.c | |
| parent | 12aead6b161a3312673ac62686af0350061c0666 (diff) | |
| parent | 964ae8cc391520440cf5aa13e2b9cc34850ea6c2 (diff) | |
Update upstream source from tag 'upstream/1.14.6'
Update to upstream version '1.14.6' with Debian dir ef09251bb8b7a4afa8e2b004d785517d8a2d973d
Diffstat (limited to 'libnm-core/nm-setting.c')
| -rw-r--r-- | libnm-core/nm-setting.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/libnm-core/nm-setting.c b/libnm-core/nm-setting.c index 6b9681b5..047391ce 100644 --- a/libnm-core/nm-setting.c +++ b/libnm-core/nm-setting.c @@ -685,10 +685,15 @@ _nm_setting_to_dbus (NMSetting *setting, NMConnection *connection, NMConnectionS continue; } - if (property->synth_func) - dbus_value = property->synth_func (setting, connection, property->name); - else + if (property->synth_func) { + if (!(flags & NM_CONNECTION_SERIALIZE_NO_SYNTH)) + dbus_value = property->synth_func (setting, connection, property->name); + else + dbus_value = NULL; + } else { dbus_value = get_property_for_dbus (setting, property, TRUE); + } + if (dbus_value) { /* Allow dbus_value to be either floating or not. */ g_variant_take_ref (dbus_value); @@ -2013,7 +2018,8 @@ nm_setting_to_string (NMSetting *setting) string = g_string_new (nm_setting_get_name (setting)); g_string_append_c (string, '\n'); - variant = _nm_setting_to_dbus (setting, NULL, NM_CONNECTION_SERIALIZE_ALL); + variant = _nm_setting_to_dbus (setting, NULL, NM_CONNECTION_SERIALIZE_ALL + | NM_CONNECTION_SERIALIZE_NO_SYNTH); g_variant_iter_init (&iter, variant); while ((child = g_variant_iter_next_value (&iter))) { |