/* It does work common to all Bluetooth encapsulations, and then calls the dissector registered in the bluetooth.encap table to handle the metadata header in the packet.  */
static gint dissect_bluetooth(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
/* It does work common to all Bluetooth encapsulations, and then calls the dissector registered in the bluetooth.encap table to handle the metadata header in the packet.  */
static gint dissect_bluetooth(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
{
    bluetooth_data_t  *bluetooth_data;
    bluetooth_data = dissect_bluetooth_common(tvb, pinfo, tree);
    bluetooth_data->previous_protocol_data_type = BT_PD_NONE;
    bluetooth_data->previous_protocol_data.none = NULL;
    if (!dissector_try_uint_new(bluetooth_table, pinfo->phdr->pkt_encap, tvb, pinfo, tree, TRUE, bluetooth_data)) {
        call_data_dissector(tvb, pinfo, tree);
    }
    return tvb_captured_length(tvb);
}