summaryrefslogtreecommitdiffstats
path: root/audio
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2008-10-24 15:49:52 +0300
committerJohan Hedberg <johan.hedberg@nokia.com>2008-10-24 15:49:52 +0300
commita5883ecb1aa94b09bcf0e7ce4184d262027c5939 (patch)
tree80ce381543b85d61ea54f930a25d08ebabc1291c /audio
parentfffc600099fdd44e485fa4925a599d790424f881 (diff)
Use g_dbus_send_message instead of dbus_connection_send
Diffstat (limited to 'audio')
-rw-r--r--audio/headset.c9
-rw-r--r--audio/sink.c9
2 files changed, 6 insertions, 12 deletions
diff --git a/audio/headset.c b/audio/headset.c
index 107618e5..648185b5 100644
--- a/audio/headset.c
+++ b/audio/headset.c
@@ -540,8 +540,7 @@ static void sco_connect_cb(GIOChannel *chan, int err, const bdaddr_t *src,
if (p->msg) {
DBusMessage *reply = dbus_message_new_method_return(p->msg);
- dbus_connection_send(dev->conn, reply, NULL);
- dbus_message_unref(reply);
+ g_dbus_send_message(dev->conn, reply);
}
pending_connect_finalize(dev);
@@ -610,8 +609,7 @@ static void hfp_slc_complete(struct audio_device *dev)
if (p->target_state == HEADSET_STATE_CONNECTED) {
if (p->msg) {
DBusMessage *reply = dbus_message_new_method_return(p->msg);
- dbus_connection_send(dev->conn, reply, NULL);
- dbus_message_unref(reply);
+ g_dbus_send_message(dev->conn, reply);
}
pending_connect_finalize(dev);
return;
@@ -1216,8 +1214,7 @@ static void rfcomm_connect_cb(GIOChannel *chan, int err, const bdaddr_t *src,
if (p->msg) {
DBusMessage *reply = dbus_message_new_method_return(p->msg);
- dbus_connection_send(dev->conn, reply, NULL);
- dbus_message_unref(reply);
+ g_dbus_send_message(dev->conn, reply);
}
pending_connect_finalize(dev);
diff --git a/audio/sink.c b/audio/sink.c
index e216980a..ea8570ac 100644
--- a/audio/sink.c
+++ b/audio/sink.c
@@ -100,8 +100,7 @@ static void stream_state_changed(struct avdtp_stream *stream,
sink->disconnect = NULL;
reply = dbus_message_new_method_return(p->msg);
- dbus_connection_send(p->conn, reply, NULL);
- dbus_message_unref(reply);
+ g_dbus_send_message(p->conn, reply);
pending_request_free(p);
}
@@ -168,8 +167,7 @@ static gboolean stream_setup_retry(gpointer user_data)
DBusMessage *reply;
debug("Stream successfully created, after XCASE connect:connect");
reply = dbus_message_new_method_return(pending->msg);
- dbus_connection_send(pending->conn, reply, NULL);
- dbus_message_unref(reply);
+ g_dbus_send_message(pending->conn, reply);
} else {
debug("Stream setup failed, after XCASE connect:connect");
error_failed(pending->conn, pending->msg, "Stream setup failed");
@@ -194,8 +192,7 @@ static void stream_setup_complete(struct avdtp *session, struct a2dp_sep *sep,
DBusMessage *reply;
sink->connect = NULL;
reply = dbus_message_new_method_return(pending->msg);
- dbus_connection_send(pending->conn, reply, NULL);
- dbus_message_unref(reply);
+ g_dbus_send_message(pending->conn, reply);
pending_request_free(pending);
debug("Stream successfully created");
} else {