linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] core/advertising: Fix byte order for MGMT_OP_ADD_ADVERTISING flags
@ 2015-07-22 10:54 Andrejs Hanins
  2015-07-24 17:55 ` Vinicius Costa Gomes
  2016-03-17  8:02 ` Johan Hedberg
  0 siblings, 2 replies; 4+ messages in thread
From: Andrejs Hanins @ 2015-07-22 10:54 UTC (permalink / raw)
  To: linux-bluetooth@vger.kernel.org

Fix byte order for MGMT_OP_ADD_ADVERTISING flags
---
 src/advertising.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/advertising.c b/src/advertising.c
index d56b7a2..8c249d1 100644
--- a/src/advertising.c
+++ b/src/advertising.c
@@ -500,7 +500,7 @@ static DBusMessage *refresh_advertisement(struct advertisement *ad)
 		return btd_error_failed(ad->reg, "Failed");
 	}
 
-	cp->flags = flags;
+	cp->flags = htobl(flags);
 	cp->instance = ad->instance;
 	cp->adv_data_len = adv_data_len;
 	memcpy(cp->data, adv_data, adv_data_len);
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] core/advertising: Fix byte order for MGMT_OP_ADD_ADVERTISING flags
  2015-07-22 10:54 [PATCH] core/advertising: Fix byte order for MGMT_OP_ADD_ADVERTISING flags Andrejs Hanins
@ 2015-07-24 17:55 ` Vinicius Costa Gomes
  2016-03-17  8:02 ` Johan Hedberg
  1 sibling, 0 replies; 4+ messages in thread
From: Vinicius Costa Gomes @ 2015-07-24 17:55 UTC (permalink / raw)
  To: Andrejs Hanins, linux-bluetooth@vger.kernel.org

Hi,

Andrejs Hanins <andrejs.hanins@ubnt.com> writes:

> Fix byte order for MGMT_OP_ADD_ADVERTISING flags
> ---
>  src/advertising.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>

Looks good.

> diff --git a/src/advertising.c b/src/advertising.c
> index d56b7a2..8c249d1 100644
> --- a/src/advertising.c
> +++ b/src/advertising.c
> @@ -500,7 +500,7 @@ static DBusMessage *refresh_advertisement(struct advertisement *ad)
>  		return btd_error_failed(ad->reg, "Failed");
>  	}
>
> -	cp->flags = flags;
> +	cp->flags = htobl(flags);
>  	cp->instance = ad->instance;
>  	cp->adv_data_len = adv_data_len;
>  	memcpy(cp->data, adv_data, adv_data_len);
> --
> 1.9.1


Cheers,
--
Vinicius

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] core/advertising: Fix byte order for MGMT_OP_ADD_ADVERTISING flags
  2015-07-22 10:54 [PATCH] core/advertising: Fix byte order for MGMT_OP_ADD_ADVERTISING flags Andrejs Hanins
  2015-07-24 17:55 ` Vinicius Costa Gomes
@ 2016-03-17  8:02 ` Johan Hedberg
  2016-03-17 10:08   ` Andrejs Hanins
  1 sibling, 1 reply; 4+ messages in thread
From: Johan Hedberg @ 2016-03-17  8:02 UTC (permalink / raw)
  To: Andrejs Hanins; +Cc: linux-bluetooth@vger.kernel.org

Hi,

On Wed, Jul 22, 2015, Andrejs Hanins wrote:
> Fix byte order for MGMT_OP_ADD_ADVERTISING flags
> ---
>  src/advertising.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/advertising.c b/src/advertising.c
> index d56b7a2..8c249d1 100644
> --- a/src/advertising.c
> +++ b/src/advertising.c
> @@ -500,7 +500,7 @@ static DBusMessage *refresh_advertisement(struct advertisement *ad)
>  		return btd_error_failed(ad->reg, "Failed");
>  	}
>  
> -	cp->flags = flags;
> +	cp->flags = htobl(flags);
>  	cp->instance = ad->instance;
>  	cp->adv_data_len = adv_data_len;
>  	memcpy(cp->data, adv_data, adv_data_len);

I'm surprised you never pinged about this forgotten patch (which I
noticed now when cleaning up my linux-bluetooth folder). Anyway, the
patch has been applied. Thanks.

Johan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] core/advertising: Fix byte order for MGMT_OP_ADD_ADVERTISING flags
  2016-03-17  8:02 ` Johan Hedberg
@ 2016-03-17 10:08   ` Andrejs Hanins
  0 siblings, 0 replies; 4+ messages in thread
From: Andrejs Hanins @ 2016-03-17 10:08 UTC (permalink / raw)
  To: linux-bluetooth@vger.kernel.org

Hi,

On 03/17/2016 10:02 AM, Johan Hedberg wrote:
> Hi,
>
> On Wed, Jul 22, 2015, Andrejs Hanins wrote:
>> Fix byte order for MGMT_OP_ADD_ADVERTISING flags
>> ---
>>  src/advertising.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/src/advertising.c b/src/advertising.c
>> index d56b7a2..8c249d1 100644
>> --- a/src/advertising.c
>> +++ b/src/advertising.c
>> @@ -500,7 +500,7 @@ static DBusMessage *refresh_advertisement(struct advertisement *ad)
>>  		return btd_error_failed(ad->reg, "Failed");
>>  	}
>>  
>> -	cp->flags = flags;
>> +	cp->flags = htobl(flags);
>>  	cp->instance = ad->instance;
>>  	cp->adv_data_len = adv_data_len;
>>  	memcpy(cp->data, adv_data, adv_data_len);
> I'm surprised you never pinged about this forgotten patch (which I
> noticed now when cleaning up my linux-bluetooth folder). Anyway, the
> patch has been applied. Thanks.
I was hoping that subject is an immediate attention grabber :)
I'm glad it is finally applied.
>
> Johan


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2016-03-17 10:08 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-22 10:54 [PATCH] core/advertising: Fix byte order for MGMT_OP_ADD_ADVERTISING flags Andrejs Hanins
2015-07-24 17:55 ` Vinicius Costa Gomes
2016-03-17  8:02 ` Johan Hedberg
2016-03-17 10:08   ` Andrejs Hanins

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).