forked from osmocom/wireshark
From Michal Labedzki:
Bluetooth: Fix uninitialized fields on the USB side Also make indentation/spaces cleanup in hci_usb dissector. Part of: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5032 svn path=/trunk/; revision=46341
This commit is contained in:
parent
191aaba217
commit
ccb3fb14e2
|
@ -148,7 +148,6 @@ dissect_hci_usb(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data
|
|||
pinfo->private_data = hci_data;
|
||||
|
||||
next_tvb = tvb_new_subset_remaining(tvb, offset);
|
||||
|
||||
if (!pinfo->fd->flags.visited && usb_data->endpoint <= 0x02) {
|
||||
fragment_info_t *fragment_info;
|
||||
|
||||
|
@ -156,6 +155,7 @@ dissect_hci_usb(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data
|
|||
if (fragment_info == NULL) {
|
||||
fragment_info = se_alloc(sizeof(fragment_info_t));
|
||||
fragment_info->fragment_id = 0;
|
||||
fragment_info->remaining_length = 0;
|
||||
|
||||
se_tree_insert32(fragment_info_table, session_id, fragment_info);
|
||||
}
|
||||
|
@ -180,7 +180,6 @@ dissect_hci_usb(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data
|
|||
}
|
||||
|
||||
reassembled = fragment_get_reassembled_id(pinfo, session_id, reassembled_table);
|
||||
|
||||
if (reassembled && pinfo->fd->num < reassembled->reassembled_in) {
|
||||
pitem = proto_tree_add_text(ttree, tvb, offset, -1, "Fragment");
|
||||
PROTO_ITEM_SET_GENERATED(pitem);
|
||||
|
|
|
@ -2308,6 +2308,8 @@ dissect_linux_usb_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent,
|
|||
offset += 40; /* skip first part of the pseudo-header */
|
||||
|
||||
usb_data = se_alloc(sizeof(usb_data_t));
|
||||
usb_data->bus_id = bus_id;
|
||||
usb_data->device_address = device_address;
|
||||
usb_data->endpoint = endpoint;
|
||||
|
||||
if (tvb_get_guint8(tvb, 10) & URB_TRANSFER_IN) {
|
||||
|
|
Loading…
Reference in New Issue