diff options
author | Johan Hedberg <johan.hedberg@nokia.com> | 2007-08-14 19:59:40 +0000 |
---|---|---|
committer | Johan Hedberg <johan.hedberg@nokia.com> | 2007-08-14 19:59:40 +0000 |
commit | 6a069310ac7270e67c58dd13674c4a13860356a0 (patch) | |
tree | 88892482bb7516141a02a0588370310de2f87d72 /audio/sink.c | |
parent | 331b4149a00410541af376a9ffce540bdada06bd (diff) |
Reset sink->c before calling get_config to avoid EBUSY
Diffstat (limited to 'audio/sink.c')
-rw-r--r-- | audio/sink.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/audio/sink.c b/audio/sink.c index 4bf17e01..f7052fb6 100644 --- a/audio/sink.c +++ b/audio/sink.c @@ -140,6 +140,8 @@ void stream_state_changed(struct avdtp_stream *stream, avdtp_state_t old_state, sink->state = new_state; if (c) { + sink->c = NULL; + if (c->msg) { reply = dbus_message_new_method_return(c->msg); send_message_and_unref(dev->conn, reply); @@ -159,7 +161,6 @@ void stream_state_changed(struct avdtp_stream *stream, avdtp_state_t old_state, } pending_connect_free(c); - sink->c = NULL; } return; |