summaryrefslogtreecommitdiff
path: root/tools/avinfo.c
diff options
context:
space:
mode:
authorAndrzej Kaczmarek <andrzej.kaczmarek@tieto.com>2014-05-26 15:16:38 +0200
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>2014-05-27 17:56:36 +0300
commit73f55340288d8c7368376c2c95ef9726fd525c4e (patch)
tree311e34658977aac9af4882a6ea37e1f59faa408c /tools/avinfo.c
parent3c5413c3dd519ebbe385f480db0e3780d16d6b54 (diff)
downloadbluez-73f55340288d8c7368376c2c95ef9726fd525c4e.tar.gz
audio: Fix a2dp_vendor_codec_t declaration
As per A2DP spec, both Vendor ID (4.7.2.1) and Codec ID (4.7.2.2) are defined as 32-bit and 16-bit values respectively rather that array of bytes. Also changing to uint types will make using these values in code much easier.
Diffstat (limited to 'tools/avinfo.c')
-rw-r--r--tools/avinfo.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/tools/avinfo.c b/tools/avinfo.c
index a4deaac13..e7747db35 100644
--- a/tools/avinfo.c
+++ b/tools/avinfo.c
@@ -162,12 +162,10 @@ static void print_vendor(a2dp_vendor_codec_t *vendor)
{
printf("\tMedia Codec: Vendor Specific A2DP Codec");
- printf("\n\t\tVendor ID 0x%02x%02x%02x%02x", vendor->vendor_id[0],
- vendor->vendor_id[1], vendor->vendor_id[2],
- vendor->vendor_id[3]);
+ printf("\n\t\tVendor ID 0x%08x", btohl(vendor->vendor_id));
- printf("\n\t\tVendor Specific Codec ID 0x%02x%02x\n",
- vendor->codec_id[0], vendor->codec_id[1]);
+ printf("\n\t\tVendor Specific Codec ID 0x%04x\n",
+ btohs(vendor->codec_id));
}
static void print_mpeg24(a2dp_mpeg_t *mpeg)