Linux bluetooth development
 help / color / mirror / Atom feed
From: Szymon Janc <szymon.janc@tieto.com>
To: Marcin Kraglak <marcin.kraglak@tieto.com>
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: [PATCH] android/gatt: Fix setting end handle
Date: Wed, 19 Nov 2014 15:31:10 +0100	[thread overview]
Message-ID: <1671726.bR4nEh2CV5@uw000953> (raw)
In-Reply-To: <1416404729-32570-1-git-send-email-marcin.kraglak@tieto.com>

Hi Marcin,

On Wednesday 19 of November 2014 14:45:29 Marcin Kraglak wrote:
> If found attribute was service attribute, range->end was always set
> to 1, because gatt_db_attribute_get_service_handles return bool.
> 
> > ACL Data RX: Handle 8 flags 0x02 dlen 13
>       ATT: Find By Type Value Request (0x06) len 8
>         Handle range: 0x0002-0xffff
>         Attribute type: Primary Service (0x2800)
>           UUID: Device Information (0x180a)
> < ACL Data TX: Handle 8 flags 0x00 dlen 9
>       ATT: Find By Type Value Response (0x07) len 4
>         Handle range: 0x0008-0x0001
> ---
>  android/gatt.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/android/gatt.c b/android/gatt.c
> index ddc1561..ea5cead 100644
> --- a/android/gatt.c
> +++ b/android/gatt.c
> @@ -4532,15 +4532,15 @@ static void send_dev_complete_response(struct gatt_device *device,
>  
>  			range->start = gatt_db_attribute_get_handle(
>  								val->attrib);
> -			range->end = range->start;
>  
>  			type = gatt_db_attribute_get_type(val->attrib);
>  			if (is_service(type))
> -				range->end =
> -					gatt_db_attribute_get_service_handles(
> +				gatt_db_attribute_get_service_handles(
>  								val->attrib,
>  								NULL,
>  								&range->end);
> +			else
> +				range->end = range->start;
>  
>  			list = g_slist_append(list, range);
>  

Applied, thanks. 

-- 
Best regards, 
Szymon Janc

      reply	other threads:[~2014-11-19 14:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-19 13:45 [PATCH] android/gatt: Fix setting end handle Marcin Kraglak
2014-11-19 14:31 ` Szymon Janc [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=1671726.bR4nEh2CV5@uw000953 \
    --to=szymon.janc@tieto.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=marcin.kraglak@tieto.com \
    /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