summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2015-07-02 11:56:19 -0700
committerGuy Harris <guy@alum.mit.edu>2015-07-02 18:57:18 +0000
commit7e461a91bf320b509cffea81fc2611bcf6b06935 (patch)
tree2deaf27ffb5da8268160c38b12c99058180907ca
parent90af3dedd578b0fddbbabf3e472b702facdea628 (diff)
downloadwireshark-7e461a91bf320b509cffea81fc2611bcf6b06935.tar.gz
Remove check for null bluetooth_data.
It's guaranteed to be non-null at that point. as noted by Coverity. Should fix CID 1306904. Fix indentation while we're at it. Change-Id: I414844e9b6f9f01e215f42ba087a56b0544d289a Reviewed-on: https://code.wireshark.org/review/9471 Reviewed-by: Guy Harris <guy@alum.mit.edu>
-rw-r--r--epan/dissectors/packet-bthci_evt.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/epan/dissectors/packet-bthci_evt.c b/epan/dissectors/packet-bthci_evt.c
index 5378b0cccb..02b15c4b0f 100644
--- a/epan/dissectors/packet-bthci_evt.c
+++ b/epan/dissectors/packet-bthci_evt.c
@@ -4157,20 +4157,15 @@ dissect_bthci_evt(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *dat
guint8 status;
switch(opcode) {
- case 0x0c13: /* Change Local Name */
+ case 0x0c13: /* Change Local Name */
status = tvb_get_guint8(tvb, 5);
if (status == STATUS_SUCCESS && have_tap_listener(bluetooth_device_tap)) {
bluetooth_device_tap_t *tap_device;
tap_device = wmem_new(wmem_packet_scope(), bluetooth_device_tap_t);
- if (bluetooth_data) {
- tap_device->interface_id = bluetooth_data->interface_id;
- tap_device->adapter_id = bluetooth_data->adapter_id;
- } else {
- tap_device->interface_id = HCI_INTERFACE_DEFAULT;
- tap_device->adapter_id = HCI_ADAPTER_DEFAULT;
- }
+ tap_device->interface_id = bluetooth_data->interface_id;
+ tap_device->adapter_id = bluetooth_data->adapter_id;
tap_device->has_bd_addr = FALSE;
tap_device->is_local = TRUE;
tap_device->type = BLUETOOTH_DEVICE_NAME;