aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2008-12-18 22:58:45 +0100
committerMarcel Holtmann <marcel@holtmann.org>2008-12-18 22:58:45 +0100
commit12c2eab4c0bce8ed6f5f31d01811ac2ce710fd0a (patch)
tree8cf829a11233a352948b5298a564a31fd96b47dc
parent1139c84bfdd7aec6e16c4b2a41df7215c62d3ba1 (diff)
downloadconnman-gnome-12c2eab4c0bce8ed6f5f31d01811ac2ce710fd0a.tar.gz
Check for errors from properties callback
-rw-r--r--common/connman-dbus.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/common/connman-dbus.c b/common/connman-dbus.c
index 4b7c049..407a53e 100644
--- a/common/connman-dbus.c
+++ b/common/connman-dbus.c
@@ -288,7 +288,9 @@ static void network_properties(DBusGProxy *proxy, GHashTable *hash,
guint strength, security;
GtkTreeIter iter, parent;
- if (hash == NULL)
+ DBG("store %p proxy %p hash %p", store, proxy, hash);
+
+ if (error != NULL || hash == NULL)
goto done;
value = g_hash_table_lookup(hash, "Device");
@@ -380,7 +382,9 @@ static void device_properties(DBusGProxy *proxy, GHashTable *hash,
gboolean powered;
GtkTreeIter iter;
- if (hash == NULL)
+ DBG("store %p proxy %p hash %p", store, proxy, hash);
+
+ if (error != NULL || hash == NULL)
goto done;
value = g_hash_table_lookup(hash, "Name");
@@ -526,6 +530,9 @@ static void manager_properties(DBusGProxy *proxy, GHashTable *hash,
DBG("store %p proxy %p hash %p", store, proxy, hash);
+ if (error != NULL || hash == NULL)
+ return;
+
value = g_hash_table_lookup(hash, "State");
state = value ? g_value_dup_string(value) : NULL;
g_object_set_data(G_OBJECT(store), "State", state);