diff options
author | Michael Mann <mmann78@netscape.net> | 2013-11-02 19:20:04 +0000 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2013-11-02 19:20:04 +0000 |
commit | a267501b82a84ab3d5b9cb7d2f06129d5ca57e42 (patch) | |
tree | 056e815b8f475e4c3b5ae57d80f89e202d47aa13 /epan/dissectors/packet-btamp.c | |
parent | 2c85824a469dba2edc674f29a18058bcec19139e (diff) |
Bluetooth: Use dissector data instead of pinfo->private_data. Bug 7893 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7893)
From Michal Labedzki
svn path=/trunk/; revision=53051
Diffstat (limited to 'epan/dissectors/packet-btamp.c')
-rw-r--r-- | epan/dissectors/packet-btamp.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/epan/dissectors/packet-btamp.c b/epan/dissectors/packet-btamp.c index 6615d95c05..06582e7d82 100644 --- a/epan/dissectors/packet-btamp.c +++ b/epan/dissectors/packet-btamp.c @@ -381,7 +381,8 @@ static int dissect_btamp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_) { int offset = 0; - proto_tree *btamp_tree = NULL; + proto_item *ti; + proto_tree *btamp_tree; guint16 length; proto_item *ti_command; proto_tree *btamp_cmd_tree; @@ -403,11 +404,8 @@ dissect_btamp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U break; } - if (tree) { - proto_item *ti; - ti = proto_tree_add_item(tree, proto_btamp, tvb, offset, -1, ENC_NA); - btamp_tree = proto_item_add_subtree(ti, ett_btamp); - } + ti = proto_tree_add_item(tree, proto_btamp, tvb, offset, -1, ENC_NA); + btamp_tree = proto_item_add_subtree(ti, ett_btamp); length = tvb_reported_length_remaining(tvb, offset); ti_command = proto_tree_add_none_format(btamp_tree, |