OSDN Git Service

AVRCP: Fix sending invalid attributes when responding to GetElementAttributes
authorLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Thu, 6 Jun 2013 04:06:45 +0000 (11:06 +0700)
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Tue, 11 Jun 2013 12:31:53 +0000 (15:31 +0300)
commit52ca0cb394f96aa4f1b98b72d8fe1dd3125f8cd0
tree69de9125b00bef27196783540aec7fc545626908
parent09dda27b12137edbfa80c27aa1811a21f1c7aca8
AVRCP: Fix sending invalid attributes when responding to GetElementAttributes

The list returned by media.c contains the attributes in string format not
the binary format which cause us to send wrong/reserved attributes as can
be observed bellow:

> ACL data: handle 12 flags 0x02 dlen 58
    L2CAP(d): cid 0x0041 len 54 [psm 23]
      AVCTP Control: Response : pt 0x00 transaction 14 pid 0x110e
        AV/C: Stable: address 0x48 opcode 0x00
          Subunit: Panel
          Opcode: Vendor Dependent
          Company ID: 0x001958
          AVRCP: GetElementAttributes: pt Single len 0x0029
            AttributeCount: 0x05
            Attribute: 0x00df9490 (Reserved)
            CharsetID: 0x006a (UTF-8)
            AttributeValueLength: 0x0000
            AttributeValue:
            Attribute: 0x00e0e880 (Reserved)
            CharsetID: 0x006a (UTF-8)
            AttributeValueLength: 0x0000
            AttributeValue:
            Attribute: 0x00e07b00 (Reserved)
            CharsetID: 0x006a (UTF-8)
            AttributeValueLength: 0x0000
            AttributeValue:
            Attribute: 0x00e16bc0 (Reserved)
            CharsetID: 0x006a (UTF-8)
            AttributeValueLength: 0x0000
            AttributeValue:
            Attribute: 0x00e07bc0 (Reserved)
            CharsetID: 0x006a (UTF-8)
            AttributeValueLength: 0x0000
            AttributeValue:
profiles/audio/avrcp.c