summaryrefslogtreecommitdiffstats
path: root/daemon
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2008-05-29 14:43:27 +0000
committerJohan Hedberg <johan.hedberg@nokia.com>2008-05-29 14:43:27 +0000
commitcc0f97ec2cb298bde87cd3753fd96f11ce41ff64 (patch)
treee02bb5f68ca60810d2793708939306174f4aa100 /daemon
parent4baf1de49d3aad2837a968a18a7181d568ff9457 (diff)
Change name_listener API to libgdbus watch API
Diffstat (limited to 'daemon')
-rw-r--r--daemon/database.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/daemon/database.c b/daemon/database.c
index 47e21915..be6ca28c 100644
--- a/daemon/database.c
+++ b/daemon/database.c
@@ -69,7 +69,7 @@ static struct record_data *find_record(uint32_t handle, const char *sender)
return NULL;
}
-static void exit_callback(const char *name, void *user_data)
+static void exit_callback(void *user_data)
{
struct record_data *user_record = user_data;
@@ -145,9 +145,9 @@ static DBusHandlerResult add_service_record_from_xml(DBusConnection *conn,
records = g_slist_append(records, user_record);
- user_record->listener_id = name_listener_add(conn, sender,
+ user_record->listener_id = g_dbus_add_disconnect_watch(conn, sender,
exit_callback,
- user_record);
+ user_record, NULL);
reply = dbus_message_new_method_return(msg);
if (!reply)
@@ -176,7 +176,7 @@ static DBusHandlerResult remove_service_record(DBusConnection *conn,
if (!user_record)
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
- name_listener_id_remove(user_record->listener_id);
+ g_dbus_remove_watch(conn, user_record->listener_id);
remove_record_from_server(handle);