summaryrefslogtreecommitdiffstats
path: root/audio/unix.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2007-08-24 12:15:20 +0000
committerJohan Hedberg <johan.hedberg@nokia.com>2007-08-24 12:15:20 +0000
commit666938b54d631956826343ed278e2af4b982fc29 (patch)
tree90828ce9054d431a304bda457ac392cd3798bd9e /audio/unix.c
parentc3cd59ae39ebb53e27ddd99ee48f1875bd480c1d (diff)
Support up to two simultaneous streams
Diffstat (limited to 'audio/unix.c')
-rw-r--r--audio/unix.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/audio/unix.c b/audio/unix.c
index 2b9b74f0..a04c5bfb 100644
--- a/audio/unix.c
+++ b/audio/unix.c
@@ -61,10 +61,12 @@ typedef void (*notify_cb_t) (struct device *dev, void *data);
struct a2dp_data {
struct avdtp *session;
struct avdtp_stream *stream;
+ struct a2dp_sep *sep;
};
struct unix_client {
struct device *dev;
+ struct avdtp_local_sep *sep;
service_type_t type;
union {
struct a2dp_data a2dp;
@@ -335,7 +337,7 @@ proceed:
id = a2dp_source_request_stream(a2dp->session, dev,
TRUE, a2dp_setup_complete,
- client);
+ client, &a2dp->sep);
if (id == 0) {
error("request_stream failed");
goto failed;
@@ -414,7 +416,7 @@ static gboolean client_cb(GIOChannel *chan, GIOCondition cond, gpointer data)
}
if (cond & (G_IO_HUP | G_IO_ERR)) {
- debug("Unix client disconnected");
+ debug("Unix client disconnected (fd=%d)", client->sock);
if (!client->dev)
goto failed;
if (client->disconnect)
@@ -488,7 +490,7 @@ static gboolean server_cb(GIOChannel *chan, GIOCondition cond, gpointer data)
return TRUE;
}
- debug("Accepted new client connection on unix socket");
+ debug("Accepted new client connection on unix socket (fd=%d)", cli_sk);
client = g_new0(struct unix_client, 1);
client->sock = cli_sk;