summaryrefslogtreecommitdiff
path: root/gdbus
diff options
context:
space:
mode:
authorLuiz Augusto von Dentz <luiz.von.dentz@intel.com>2014-08-11 14:58:37 (GMT)
committerMarcel Holtmann <marcel@holtmann.org>2014-09-08 03:48:48 (GMT)
commit1b1b1861ab49c7740b53bafd17494592527415a4 (patch)
tree6c75d297606b4040cc5c49d7c66dd27813a5eb46 /gdbus
parent8a4c29ca74b622d3ff95c1dd2bef31aa62892024 (diff)
downloadofono-1b1b1861ab49c7740b53bafd17494592527415a4.tar.gz
ofono-1b1b1861ab49c7740b53bafd17494592527415a4.tar.xz
Revert "gdbus: Don't include just added interfaces in GetManagedObjects"
This actually creates a problem since the code now does flush any pending message on the queue any signal will be send right away before the actual reply to GetManagedObjects which will not contain those interfaces.
Diffstat (limited to 'gdbus')
-rw-r--r--gdbus/object.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/gdbus/object.c b/gdbus/object.c
index 13cf9a9..4d5a64c 100644
--- a/gdbus/object.c
+++ b/gdbus/object.c
@@ -1088,7 +1088,6 @@ static const GDBusMethodTable introspect_methods[] = {
static void append_interfaces(struct generic_data *data, DBusMessageIter *iter)
{
DBusMessageIter array;
- GSList *l;
dbus_message_iter_open_container(iter, DBUS_TYPE_ARRAY,
DBUS_DICT_ENTRY_BEGIN_CHAR_AS_STRING
@@ -1100,12 +1099,7 @@ static void append_interfaces(struct generic_data *data, DBusMessageIter *iter)
DBUS_DICT_ENTRY_END_CHAR_AS_STRING
DBUS_DICT_ENTRY_END_CHAR_AS_STRING, &array);
- for (l = data->interfaces; l != NULL; l = l->next) {
- if (g_slist_find(data->added, l->data))
- continue;
-
- append_interface(l->data, &array);
- }
+ g_slist_foreach(data->interfaces, append_interface, &array);
dbus_message_iter_close_container(iter, &array);
}