diff options
author | Dario Lombardo <lomato@gmail.com> | 2014-06-17 17:45:00 +0200 |
---|---|---|
committer | Anders Broman <a.broman58@gmail.com> | 2014-06-18 14:14:58 +0000 |
commit | 246fe2ca4c67d8c98caa84e2f57694f6322e2f96 (patch) | |
tree | 5f8651517a3423cce11c50e18371d8a73c3c7665 /epan/dissectors/packet-nbns.c | |
parent | 971ffd683ea23362bd8009567ff7860371e6e2cc (diff) |
Fixup: tvb_* -> tvb_captured
Change-Id: I9209c1271967405c34c1b6fa43e1726a4d3a5a3f
Reviewed-on: https://code.wireshark.org/review/2377
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-nbns.c')
-rw-r--r-- | epan/dissectors/packet-nbns.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/epan/dissectors/packet-nbns.c b/epan/dissectors/packet-nbns.c index 0e7f1ae5fe..4ac278ef88 100644 --- a/epan/dissectors/packet-nbns.c +++ b/epan/dissectors/packet-nbns.c @@ -1572,7 +1572,7 @@ dissect_continuation_packet(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) proto_tree_add_text(nbss_tree, tvb, 0, -1, "Continuation data"); } - return tvb_length(tvb); + return tvb_captured_length(tvb); } static int @@ -1597,7 +1597,7 @@ dissect_nbss(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data) col_set_str(pinfo->cinfo, COL_PROTOCOL, "NBSS"); col_clear(pinfo->cinfo, COL_INFO); - max_data = tvb_length(tvb); + max_data = tvb_captured_length(tvb); msg_type = tvb_get_guint8(tvb, offset); @@ -1653,7 +1653,7 @@ dissect_nbss(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data) * So if it is a SESSION_MESSAGE and SMB1 or SMB2 * mark it as is_cifs. */ - if (tvb_length_remaining(tvb, offset) >= 8 + if (tvb_captured_length_remaining(tvb, offset) >= 8 && tvb_get_guint8(tvb,offset+0) == SESSION_MESSAGE && tvb_get_guint8(tvb,offset+5) == 'S' && tvb_get_guint8(tvb,offset+6) == 'M' @@ -1795,7 +1795,7 @@ dissect_nbss(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data) */ pinfo->desegment_offset = offset; pinfo->desegment_len = DESEGMENT_ONE_MORE_SEGMENT; - return tvb_length(tvb); + return tvb_captured_length(tvb); } } @@ -1821,7 +1821,7 @@ dissect_nbss(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data) * there is an SMB header there ... */ if( ((int)plen>tvb_reported_length_remaining(tvb, offset)) - &&(tvb_length_remaining(tvb, offset) >= 8) + &&(tvb_captured_length_remaining(tvb, offset) >= 8) &&(tvb_get_guint8(tvb,offset+5) == 'S') &&(tvb_get_guint8(tvb,offset+6) == 'M') &&(tvb_get_guint8(tvb,offset+7) == 'B') ){ @@ -1845,7 +1845,7 @@ dissect_nbss(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data) */ pinfo->desegment_offset = offset; pinfo->desegment_len = plen - length_remaining; - return tvb_length(tvb); + return tvb_captured_length(tvb); } } @@ -1863,7 +1863,7 @@ dissect_nbss(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data) offset += plen; } - return tvb_length(tvb); + return tvb_captured_length(tvb); } void |