device: also export NMIPxConfig on error in nm_device_set_ipx_config()

A failure to configure an address family does not mean that the connection
is going to fail. It depends, for example on ipvx.may-fail.

Always export the NMIPxConfig instance in that case.
This commit is contained in:
Thomas Haller 2018-03-15 19:24:51 +01:00
parent 5fd82a2035
commit 1d88f50443

View file

@ -10550,7 +10550,7 @@ nm_device_set_ip4_config (NMDevice *self,
has_changes = TRUE;
priv->ip4_config = g_object_ref (new_config);
if (success && !nm_dbus_object_is_exported (NM_DBUS_OBJECT (new_config)))
if (!nm_dbus_object_is_exported (NM_DBUS_OBJECT (new_config)))
nm_dbus_object_export (NM_DBUS_OBJECT (new_config));
_LOGD (LOGD_IP4, "ip4-config: set IP4Config instance (%s)",
@ -10723,7 +10723,7 @@ nm_device_set_ip6_config (NMDevice *self,
has_changes = TRUE;
priv->ip6_config = g_object_ref (new_config);
if (success && !nm_dbus_object_is_exported (NM_DBUS_OBJECT (new_config)))
if (!nm_dbus_object_is_exported (NM_DBUS_OBJECT (new_config)))
nm_dbus_object_export (NM_DBUS_OBJECT (new_config));
_LOGD (LOGD_IP6, "ip6-config: set IP6Config instance (%s)",