summaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2008-10-20 14:18:33 +0300
committerJohan Hedberg <johan.hedberg@nokia.com>2008-10-20 14:18:33 +0300
commite5015624453d81d34ab049654e1af5f01e318f54 (patch)
tree8a33c1cc458f3509fee001ae69b5f0e8146df39e /plugins
parent34e61befec8a9ec737d89e85f2eeb13965adae34 (diff)
Call exit_callback with correct parameters upon path removal
Diffstat (limited to 'plugins')
-rw-r--r--plugins/service.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/service.c b/plugins/service.c
index 56dde3ff..d154255f 100644
--- a/plugins/service.c
+++ b/plugins/service.c
@@ -725,8 +725,13 @@ static GDBusMethodTable service_methods[] = {
static void path_unregister(void *data)
{
struct service_adapter *serv_adapter = data;
+ GSList *l, *next = NULL;
- g_slist_foreach(serv_adapter->records, (GFunc) exit_callback, NULL);
+ for (l = serv_adapter->records; l != NULL; l = next) {
+ struct record_data *user_record = l->data;
+ next = l->next;
+ exit_callback(connection, user_record);
+ }
}
static int service_probe(struct btd_adapter *adapter)