From: Johan Hedberg <johan.hedberg@gmail.com>
To: "João Paulo Rechi Vita" <jprvita@openbossa.org>
Cc: linux-bluetooth@vger.kernel.org,
Paulo Alcantara <paulo.alcantara@openbossa.org>
Subject: Re: [PATCH BlueZ v3 13/14] core: Disable unnecessary auto connections
Date: Fri, 17 Aug 2012 10:39:11 +0300 [thread overview]
Message-ID: <20120817073911.GA30060@x220> (raw)
In-Reply-To: <1345152524-13404-14-git-send-email-jprvita@openbossa.org>
Hi,
On Thu, Aug 16, 2012, João Paulo Rechi Vita wrote:
> BlueZ host disconnects the link when encryption fails. ECONNABORTED
> error is returned by the kernel when the connection is terminated by the
> local host. This scenario commonly happens when authentication fails due
> PIN or Key Missing.
> ---
> src/device.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/src/device.c b/src/device.c
> index 645a2b7..5490e37 100644
> --- a/src/device.c
> +++ b/src/device.c
> @@ -1956,6 +1956,9 @@ static void att_error_cb(const GError *gerr, gpointer user_data)
> struct att_callbacks *attcb = user_data;
> struct btd_device *device = attcb->user_data;
>
> + if (gerr->code == ECONNABORTED)
> + return;
> +
I think it'd be more appropriate to use g_error_matches() here.
Johan
next prev parent reply other threads:[~2012-08-17 7:39 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-16 21:28 [PATCH BlueZ v3 00/14] LE General Connection Establishment procedure João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 01/14] core: Control connections based on adapter state João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 02/14] mgmt: print error message when start_discovery fails João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 03/14] core: add compare function for bdaddr in a struct btd_device João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 04/14] core: Add a list of LE devices to connect João Paulo Rechi Vita
2012-08-17 7:42 ` Johan Hedberg
2012-08-16 21:28 ` [PATCH BlueZ v3 05/14] core: use adapter connect list for LE connections João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 06/14] core: mutually exclude concurrent connections João Paulo Rechi Vita
2012-08-17 7:51 ` Johan Hedberg
2012-08-30 22:08 ` Joao Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 07/14] mgmt: Add LE scanning callback João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 08/14] core: Replace interleaved by LE scanning João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 09/14] core: Start LE scanning when a device requests João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 10/14] core: Remove leftover define João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 11/14] core: Queue discovery if scanning is active João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 12/14] test: Fix exiting the bus when a discovery session ends João Paulo Rechi Vita
2012-08-16 21:28 ` [PATCH BlueZ v3 13/14] core: Disable unnecessary auto connections João Paulo Rechi Vita
2012-08-17 7:39 ` Johan Hedberg [this message]
2012-08-16 21:28 ` [PATCH BlueZ v3 14/14] core: Re-connect for ECONNRESET or ECONNABORTED João Paulo Rechi Vita
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=20120817073911.GA30060@x220 \
--to=johan.hedberg@gmail.com \
--cc=jprvita@openbossa.org \
--cc=linux-bluetooth@vger.kernel.org \
--cc=paulo.alcantara@openbossa.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).