Diff between 900090ef9ea8803d44c7711f2aba78ce5d3b7891 and f3dd71706adf772ae4726fcb73e958339603d53b
Changed Files
| File | Additions | Deletions | Status |
| profiles/audio/avdtp.c | +5 | -0 | modified |
Full Patch
diff --git a/profiles/audio/avdtp.c b/profiles/audio/avdtp.c
index 4c39088..16fa20b 100644
--- a/profiles/audio/avdtp.c
+++ b/profiles/audio/avdtp.c
@@ -2612,6 +2612,11 @@ static int send_req(struct avdtp *session, gboolean priority,
if (session->state == AVDTP_SESSION_STATE_DISCONNECTED) {
session->io = l2cap_connect(session);
if (!session->io) {
+ /* Report disconnection anyways, as the other layers
+ * are using this state for cleanup.
+ */
+ avdtp_set_state(session,
+ AVDTP_SESSION_STATE_DISCONNECTED);
err = -EIO;
goto failed;
}