All of lore.kernel.org
 help / color / mirror / Atom feed
From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: [PATCH BlueZ 2/3] audio/avdtp: Fix calling abort confirmation
Date: Fri, 20 Jan 2017 15:43:30 +0200	[thread overview]
Message-ID: <20170120134331.25438-2-luiz.dentz@gmail.com> (raw)
In-Reply-To: <20170120134331.25438-1-luiz.dentz@gmail.com>

From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>

Abort confirmation shall only be called in case an abort has been sent
and the setup has to be unref asynchronously.
---
 profiles/audio/avdtp.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/profiles/audio/avdtp.c b/profiles/audio/avdtp.c
index 4ec9cca..4a21e03 100644
--- a/profiles/audio/avdtp.c
+++ b/profiles/audio/avdtp.c
@@ -2442,10 +2442,9 @@ static int cancel_request(struct avdtp *session, int err)
 	else
 		stream = NULL;
 
-	if (stream) {
-		stream->abort_int = TRUE;
+	if (stream)
 		lsep = stream->lsep;
-	} else
+	else
 		lsep = NULL;
 
 	switch (req->signal_id) {
@@ -2515,6 +2514,8 @@ static int cancel_request(struct avdtp *session, int err)
 		goto failed;
 	}
 
+	stream->abort_int = TRUE;
+
 	goto done;
 
 failed:
-- 
2.9.3


  reply	other threads:[~2017-01-20 13:43 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-20 13:43 [PATCH BlueZ 1/3] audio/avctp: Match opcode when parsing responses Luiz Augusto von Dentz
2017-01-20 13:43 ` Luiz Augusto von Dentz [this message]
2017-01-20 13:43 ` [PATCH BlueZ 3/3] audio/avdtp: Fix not aborting SetConfiguration Luiz Augusto von Dentz
2017-01-25 18:04 ` [PATCH BlueZ 1/3] audio/avctp: Match opcode when parsing responses Luiz Augusto von Dentz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170120134331.25438-2-luiz.dentz@gmail.com \
    --to=luiz.dentz@gmail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.