Re: [PATCH BlueZ 3/4] device: Appearance characteristic from GAP service

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Mar 28, 2012 at 5:58 AM, Johan Hedberg <johan.hedberg@xxxxxxxxx> wrote:
> Hi Bruna,
>
> On Tue, Mar 27, 2012, Bruna Moreira wrote:
>> @@ -363,15 +367,19 @@ static DBusMessage *get_properties(DBusConnection *conn,
>>
>>       /* Class */
>>       if (read_remote_class(&src, &device->bdaddr, &class) == 0) {
>> -             const char *icon = class_to_icon(class);
>> +             icon = class_to_icon(class);
>>
>>               dict_append_entry(&dict, "Class", DBUS_TYPE_UINT32, &class);
>> +     } else if (read_remote_appearance(&src, &device->bdaddr, &app) == 0) {
>> +             /* Appearance */
>> +             icon = gap_appearance_to_icon(app);
>> +             class = 0;
>>
>> -             if (icon)
>> -                     dict_append_entry(&dict, "Icon",
>> -                                             DBUS_TYPE_STRING, &icon);
>> +             dict_append_entry(&dict, "Class", DBUS_TYPE_UINT32, &class);
>>       }
>
> If we don't have a proper remote class value wouldn't it be simpler to
> just leave it out from the properties list instead of including a 0
> value?

Agreed, I am sending a new patch fixing that. Thanks.

BR,
-- 
Bruna Moreira
Instituto Nokia de Tecnologia (INdT)
Manaus - Brazil
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux