diff options
Diffstat (limited to 'plugins/docsis/packet-uccreq.c')
-rw-r--r-- | plugins/docsis/packet-uccreq.c | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/plugins/docsis/packet-uccreq.c b/plugins/docsis/packet-uccreq.c index 856112a103..9a1a090160 100644 --- a/plugins/docsis/packet-uccreq.c +++ b/plugins/docsis/packet-uccreq.c @@ -43,26 +43,19 @@ static int dissect_uccreq (tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree, void* data _U_) { proto_item *it; - proto_tree *uccreq_tree = NULL; - guint8 chid; + proto_tree *uccreq_tree; + guint32 chid; tvbuff_t *next_tvb; - chid = tvb_get_guint8 (tvb, 0); + it = proto_tree_add_item (tree, proto_docsis_uccreq, tvb, 0, -1, ENC_NA); + uccreq_tree = proto_item_add_subtree (it, ett_docsis_uccreq); + + proto_tree_add_item_ret_uint (uccreq_tree, hf_docsis_uccreq_upchid, tvb, 0, 1, ENC_BIG_ENDIAN, &chid); col_add_fstr (pinfo->cinfo, COL_INFO, "Upstream Channel Change request Channel ID = %u (U%u)", chid, (chid > 0 ? chid - 1 : chid)); - if (tree) - { - it = - proto_tree_add_protocol_format (tree, proto_docsis_uccreq, tvb, 0, -1, - "UCC Request"); - uccreq_tree = proto_item_add_subtree (it, ett_docsis_uccreq); - proto_tree_add_item (uccreq_tree, hf_docsis_uccreq_upchid, tvb, 0, 1, - ENC_BIG_ENDIAN); - - } /* call dissector for Appendix C TLV's */ next_tvb = tvb_new_subset_remaining (tvb, 1); call_dissector (docsis_tlv_handle, next_tvb, pinfo, uccreq_tree); |