[network-manager-netbook] Don't require error argument for gconf connection updates.



commit e2815dd3c7ea6e5700bf8707ff3a87d83b52374b
Author: Tambet Ingo <tambet gmail com>
Date:   Wed May 27 12:04:18 2009 +0300

    Don't require error argument for gconf connection updates.
---
 src/gconf-helpers/nma-gconf-connection.c |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/src/gconf-helpers/nma-gconf-connection.c b/src/gconf-helpers/nma-gconf-connection.c
index 12a9cc9..4297d7c 100644
--- a/src/gconf-helpers/nma-gconf-connection.c
+++ b/src/gconf-helpers/nma-gconf-connection.c
@@ -335,14 +335,17 @@ update (NMExportedConnection *exported, GHashTable *new_settings, GError **error
 {
 	NMAGConfConnectionPrivate *priv = NMA_GCONF_CONNECTION_GET_PRIVATE (exported);
 	NMConnection *tmp;
+	GError *local_error = NULL;
 	gboolean success = FALSE;
 
-	tmp = nm_connection_new_from_hash (new_settings, error);
+	tmp = nm_connection_new_from_hash (new_settings, &local_error);
 	if (!tmp) {
 		nm_warning ("%s: Invalid connection: '%s' / '%s' invalid: %d",
 		            __func__,
-		            g_type_name (nm_connection_lookup_setting_type_by_quark ((*error)->domain)),
-		            (*error)->message, (*error)->code);
+		            g_type_name (nm_connection_lookup_setting_type_by_quark (local_error->domain)),
+		            local_error->message, local_error->code);
+
+		g_propagate_error (error, local_error);
 	} else {
 		/* Copy private values to the connection that actually gets saved */
 		nm_gconf_copy_private_connection_values (tmp, nm_exported_connection_get_connection (exported));



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]