diff options
author | Martin Kaiser <wireshark@kaiser.cx> | 2014-03-24 15:30:25 +0100 |
---|---|---|
committer | Martin Kaiser <wireshark@kaiser.cx> | 2014-03-24 14:31:27 +0000 |
commit | d04cddf6d35a64aa18ca0b7332bc69739a4f5799 (patch) | |
tree | e0be737748a19e65a82012f337a13abe93a32b53 /epan/dissectors/packet-dvbci.c | |
parent | d066376a7418d98cd030472ba8543a0897577c9b (diff) |
no need for if(tree)
Change-Id: Ia6db5839a8bbbc79a5196406e3f8d59f7ce7498a
Reviewed-on: https://code.wireshark.org/review/814
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
Diffstat (limited to 'epan/dissectors/packet-dvbci.c')
-rw-r--r-- | epan/dissectors/packet-dvbci.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/epan/dissectors/packet-dvbci.c b/epan/dissectors/packet-dvbci.c index de682a6375..f33199274b 100644 --- a/epan/dissectors/packet-dvbci.c +++ b/epan/dissectors/packet-dvbci.c @@ -3589,8 +3589,8 @@ dissect_dvbci_payload_ami(guint32 tag, gint len_field _U_, guint8 file_name_len; guint8 *file_name_str; guint32 file_data_len; - proto_item *ti = NULL; - proto_tree *req_tree = NULL; + proto_item *ti; + proto_tree *req_tree; switch(tag) { case T_REQUEST_START: @@ -3694,13 +3694,11 @@ dissect_dvbci_payload_ami(guint32 tag, gint len_field _U_, tvb_reported_length_remaining(tvb, offset), ENC_NA); } else if (req_type==REQ_TYPE_REQ) { - if (tree) { - ti = proto_tree_add_text(tree, tvb, - offset, tvb_reported_length_remaining(tvb, offset), - "Supported request types"); - req_tree = proto_item_add_subtree( - ti, ett_dvbci_ami_req_types); - } + ti = proto_tree_add_text(tree, tvb, + offset, tvb_reported_length_remaining(tvb, offset), + "Supported request types"); + req_tree = proto_item_add_subtree( + ti, ett_dvbci_ami_req_types); while (tvb_reported_length_remaining(tvb, offset) > 0) { proto_tree_add_item(req_tree, hf_dvbci_req_type, tvb, offset, 1, ENC_BIG_ENDIAN); |