summaryrefslogtreecommitdiffstats
path: root/audio/avdtp.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2007-08-18 21:57:26 +0000
committerJohan Hedberg <johan.hedberg@nokia.com>2007-08-18 21:57:26 +0000
commitc0e0aa5745b38505b180ffdd7d5df44612597e75 (patch)
tree5c0951ac25effac1d9a4f9d34975413c8847fee7 /audio/avdtp.c
parent86892be8d38960096f9b9c5613ba28fc9003d288 (diff)
Accept start requests and add timeout for suspending unused streams
Diffstat (limited to 'audio/avdtp.c')
-rw-r--r--audio/avdtp.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/audio/avdtp.c b/audio/avdtp.c
index 443f096b..8348d3d6 100644
--- a/audio/avdtp.c
+++ b/audio/avdtp.c
@@ -524,11 +524,17 @@ static void finalize_discovery(struct avdtp *session, int err)
static void release_stream(struct avdtp_stream *stream, struct avdtp *session)
{
+ struct avdtp_local_sep *sep = stream->lsep;
+
if (stream->sock >= 0)
close(stream->sock);
if (stream->io)
g_source_remove(stream->io);
- avdtp_sep_set_state(session, stream->lsep, AVDTP_STATE_IDLE);
+
+ if (sep->cfm && sep->cfm->abort)
+ sep->cfm->abort(session, sep, stream, NULL);
+
+ avdtp_sep_set_state(session, sep, AVDTP_STATE_IDLE);
}
static void connection_lost(struct avdtp *session, int err)