Linux bluetooth development
 help / color / mirror / Atom feed
From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: [PATCH 2/3] Fix not setting proper errors when canceling suspended requests
Date: Mon, 18 Oct 2010 17:18:48 +0300	[thread overview]
Message-ID: <1287411529-5806-2-git-send-email-luiz.dentz@gmail.com> (raw)
In-Reply-To: <1287411529-5806-1-git-send-email-luiz.dentz@gmail.com>

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

---
 src/obex.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/obex.c b/src/obex.c
index f37cd90..6d4430d 100644
--- a/src/obex.c
+++ b/src/obex.c
@@ -702,9 +702,10 @@ static gboolean handle_async_io(void *object, int flags, int err,
 		ret = obex_read_stream(os, os->obex, os->obj);
 
 proceed:
-	if (ret < 0)
+	if (ret < 0) {
+		os_set_response(os->obj, err);
 		OBEX_CancelRequest(os->obex, TRUE);
-	else
+	} else
 		OBEX_ResumeRequest(os->obex);
 
 	return FALSE;
-- 
1.7.1


  reply	other threads:[~2010-10-18 14:18 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-18 14:18 [PATCH 1/3] Make use of transfer->err to store transfer errors Luiz Augusto von Dentz
2010-10-18 14:18 ` Luiz Augusto von Dentz [this message]
2010-10-18 14:18 ` [PATCH 3/3] Fix possible invalid read Luiz Augusto von Dentz
2010-10-20  8:57 ` [PATCH 1/3] Make use of transfer->err to store transfer errors Johan Hedberg

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=1287411529-5806-2-git-send-email-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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox