From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: [PATCH obexd 01/13] client: fix not checking session_request return
Date: Mon, 30 Jan 2012 07:30:24 -0800 [thread overview]
Message-ID: <1327937436-15480-1-git-send-email-luiz.dentz@gmail.com> (raw)
From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
In case session_request return an error proceed to the next
---
client/session.c | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/client/session.c b/client/session.c
index c127974..c9df832 100644
--- a/client/session.c
+++ b/client/session.c
@@ -687,9 +687,16 @@ static void session_terminate_transfer(struct obc_session *session,
obc_session_remove_transfer(session, transfer);
- if (session->pending)
- session_request(session, session_prepare_put,
- session->pending->data);
+ while (session->pending != NULL) {
+ struct obc_transfer *transfer = session->pending->data;
+ int err;
+
+ err = session_request(session, session_prepare_put, transfer);
+ if (err == 0)
+ break;
+
+ obc_session_remove_transfer(session, transfer);
+ }
obc_session_unref(session);
}
--
1.7.7.6
next reply other threads:[~2012-01-30 15:30 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-30 15:30 Luiz Augusto von Dentz [this message]
2012-01-30 15:30 ` [PATCH obexd 02/13] client: remove unused field from obc_session Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 03/13] client: fix not queuing requests properly Luiz Augusto von Dentz
2012-01-31 13:28 ` Mikel Astiz
2012-01-31 16:39 ` Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 04/13] client: introduce obc_session_setpath Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 05/13] client: introduce obc_session_mkdir Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 06/13] client: introduce obc_session_copy Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 07/13] client: introduce obc_session_move Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 08/13] client: introduce obc_session_delete Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 09/13] client: introduce obc_session_cancel Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 10/13] client: remove use of gobex in pbap module Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 11/13] client: remove use of gobex in map module Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 12/13] client: remove use of gobex in ftp module Luiz Augusto von Dentz
2012-01-30 15:30 ` [PATCH obexd 13/13] client: remove gobex dependency of session 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=1327937436-15480-1-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;
as well as URLs for NNTP newsgroup(s).