settings: unify settings-update API (drop internal _update())

This commit is contained in:
Thomas Haller 2017-12-01 10:09:43 +01:00
parent 776c5f3893
commit 141dfd600c

View file

@ -552,13 +552,13 @@ _update_prepare (NMSettingsConnection *self,
return TRUE;
}
static gboolean
_update (NMSettingsConnection *self,
NMConnection *new_connection,
NMSettingsConnectionPersistMode persist_mode,
NMSettingsConnectionCommitReason commit_reason,
const char *log_diff_name,
GError **error)
gboolean
nm_settings_connection_update (NMSettingsConnection *self,
NMConnection *new_connection,
NMSettingsConnectionPersistMode persist_mode,
NMSettingsConnectionCommitReason commit_reason,
const char *log_diff_name,
GError **error)
{
NMSettingsConnectionPrivate *priv;
NMSettingsConnectionClass *klass = NULL;
@ -693,22 +693,6 @@ out:
return TRUE;
}
gboolean
nm_settings_connection_update (NMSettingsConnection *self,
NMConnection *new_connection,
NMSettingsConnectionPersistMode persist_mode,
NMSettingsConnectionCommitReason commit_reason,
const char *log_diff_name,
GError **error)
{
return _update (self,
new_connection,
persist_mode,
commit_reason,
log_diff_name,
error);
}
static void
remove_entry_from_db (NMSettingsConnection *self, const char* db_name)
{
@ -1734,12 +1718,12 @@ update_auth_cb (NMSettingsConnection *self,
TRUE);
}
_update (self,
info->new_settings,
persist_mode,
commit_reason,
log_diff_name,
&local);
nm_settings_connection_update (self,
info->new_settings,
persist_mode,
commit_reason,
log_diff_name,
&local);
if (!local) {
gs_unref_object NMConnection *for_agent = NULL;