From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: "linux-bluetooth@vger.kernel.org" <linux-bluetooth@vger.kernel.org>
Subject: Re: [PATCH BlueZ] core/gatt-client: Fix printing errors if experimental is disabled
Date: Wed, 2 Mar 2016 12:53:46 +0200 [thread overview]
Message-ID: <CABBYNZLaz7VDV9FVBHYAx6ux9X7wyaDpExTmbUR=5AOPkKkjzA@mail.gmail.com> (raw)
In-Reply-To: <1456759739-22626-1-git-send-email-luiz.dentz@gmail.com>
Hi,
On Mon, Feb 29, 2016 at 5:28 PM, Luiz Augusto von Dentz
<luiz.dentz@gmail.com> wrote:
> From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
>
> If experimental flag is not set don't attempt to create any objects since
> it will cause error that are hard to guess such as bellow:
>
> bluetoothd[6539]: Unable to register GATT service with handle 0x000c for device
> ---
> src/gatt-client.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/src/gatt-client.c b/src/gatt-client.c
> index b4ca3b6..dd76a36 100644
> --- a/src/gatt-client.c
> +++ b/src/gatt-client.c
> @@ -1688,6 +1688,12 @@ static void export_service(struct gatt_db_attribute *attr, void *user_data)
>
> static void create_services(struct btd_gatt_client *client)
> {
> + /* Don't attempt to create any objects if experimental is disabled */
> + if (!(g_dbus_get_flags() & G_DBUS_FLAG_ENABLE_EXPERIMENTAL)) {
> + info("GATT service objects disabled");
> + return;
> + }
> +
> DBG("Exporting objects for GATT services: %s", client->devaddr);
>
> gatt_db_foreach_service(client->db, NULL, export_service, client);
> --
> 2.5.0
Applied.
--
Luiz Augusto von Dentz
prev parent reply other threads:[~2016-03-02 10:53 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-29 15:28 [PATCH BlueZ] core/gatt-client: Fix printing errors if experimental is disabled Luiz Augusto von Dentz
2016-03-02 10:53 ` Luiz Augusto von Dentz [this message]
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='CABBYNZLaz7VDV9FVBHYAx6ux9X7wyaDpExTmbUR=5AOPkKkjzA@mail.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).