aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-bthci_vendor.c
diff options
context:
space:
mode:
authorMichal Labedzki <michal.labedzki@tieto.com>2015-01-17 15:07:47 +0100
committerMichal Labedzki <michal.labedzki@tieto.com>2015-02-02 10:47:50 +0000
commitc4f08ec0f92c3d97bf398f27cd3196e8e7713a2a (patch)
tree567a42ba4ba68950b244519fd57e1654b7e2ba1d /epan/dissectors/packet-bthci_vendor.c
parent359ff3100b06b5e7bacbb199830b2d9a814d3a41 (diff)
Bluetooth: HCI Vendor: Fix for "Enable WBS" command
Codec value for mSBC is 0x02 (not 0x01), also "Codec" field does not appear when Codec state in Disable. Change-Id: I4f0b27d0dc8659fdc054eaf18b54a42aad60275b Reviewed-on: https://code.wireshark.org/review/6899 Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
Diffstat (limited to 'epan/dissectors/packet-bthci_vendor.c')
-rw-r--r--epan/dissectors/packet-bthci_vendor.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/epan/dissectors/packet-bthci_vendor.c b/epan/dissectors/packet-bthci_vendor.c
index eb7b942487..c97d200bb0 100644
--- a/epan/dissectors/packet-bthci_vendor.c
+++ b/epan/dissectors/packet-bthci_vendor.c
@@ -223,7 +223,7 @@ static const value_string codec_state_vals[] = {
static const value_string codec_vals[] = {
{ 0x00, "None" },
{ 0x01, "CVSD" },
- { 0x01, "mSBC" },
+ { 0x02, "mSBC" },
{ 0, NULL }
};
@@ -553,10 +553,13 @@ dissect_bthci_vendor_broadcom(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tre
break;
case 0x007E: /* Enable WBS */
proto_tree_add_item(main_tree, hf_codec_state, tvb, offset, 1, ENC_NA);
+ status = tvb_get_guint8(tvb, offset);
offset += 1;
- proto_tree_add_item(main_tree, hf_codec, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset += 2;
+ if (status == 0x01) { /* Enable */
+ proto_tree_add_item(main_tree, hf_codec, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset += 2;
+ }
break;
case 0x0154: /* LE Multi Adveritising */
proto_tree_add_item(main_tree, hf_le_multi_advertising_subcode, tvb, offset, 1, ENC_NA);