summaryrefslogtreecommitdiffstats
path: root/audio/sink.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2007-08-13 20:33:35 +0000
committerJohan Hedberg <johan.hedberg@nokia.com>2007-08-13 20:33:35 +0000
commitab81dc1b10048188c2005dc29bbdb45f42c10c95 (patch)
tree350e04255ab175f344a37424391075d732cd72ad /audio/sink.c
parenta87207e7f3b81bf3bbea9cd4b92de9b274cca3ac (diff)
Don't perform any additional actions if not the initiator of a stream
Diffstat (limited to 'audio/sink.c')
-rw-r--r--audio/sink.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/audio/sink.c b/audio/sink.c
index 237fcaee..64d0a27d 100644
--- a/audio/sink.c
+++ b/audio/sink.c
@@ -113,6 +113,10 @@ void stream_state_changed(struct avdtp_stream *stream, avdtp_state_t old_state,
AUDIO_SINK_INTERFACE,
"Connected",
DBUS_TYPE_INVALID);
+
+ if (!sink->initiator)
+ break;
+
if (sink->c && sink->c->pkt) {
cmd_err = avdtp_start(sink->session, stream);
if (cmd_err < 0) {