aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-mbtcp.c
diff options
context:
space:
mode:
authorEvan Huus <eapache@gmail.com>2015-06-23 17:22:18 -0700
committerEvan Huus <eapache@gmail.com>2015-06-24 00:22:50 +0000
commitf92fab41a5266cb380c443882ce5efd5a7ee3318 (patch)
tree13e190875507342a2c5847b2629a6dab44d2d61d /epan/dissectors/packet-mbtcp.c
parentad784bc7ce29c2d8ad64bca73e4863a6353c578f (diff)
Remove a bunch more deprecated tvb_length calls
(getting really close!) Change-Id: Ibf22a5f727c4dc0070b78144a4b0ab8e0c5e1bce Reviewed-on: https://code.wireshark.org/review/9081 Reviewed-by: Evan Huus <eapache@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-mbtcp.c')
-rw-r--r--epan/dissectors/packet-mbtcp.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/epan/dissectors/packet-mbtcp.c b/epan/dissectors/packet-mbtcp.c
index 6bd436e5e2..fb9f47029a 100644
--- a/epan/dissectors/packet-mbtcp.c
+++ b/epan/dissectors/packet-mbtcp.c
@@ -528,7 +528,7 @@ dissect_mbtcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* dat
p_add_proto_data(wmem_file_scope(), pinfo, proto_modbus, 0, request_info);
/* Continue with dissection of Modbus data payload following Modbus/TCP frame */
- if( tvb_length_remaining(tvb, offset) > 0 )
+ if( tvb_reported_length_remaining(tvb, offset) > 0 )
call_dissector(modbus_handle, next_tvb, pinfo, tree);
p_remove_proto_data(wmem_file_scope(), pinfo, proto_modbus, 0);
@@ -557,7 +557,7 @@ dissect_mbrtu_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* dat
col_set_str(pinfo->cinfo, COL_PROTOCOL, "Modbus RTU");
col_clear(pinfo->cinfo, COL_INFO);
- len = tvb_length(tvb);
+ len = tvb_reported_length(tvb);
unit_id = tvb_get_guint8(tvb, 0);
function_code = tvb_get_guint8(tvb, 1) & 0x7F;
@@ -670,7 +670,7 @@ dissect_mbrtu_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* dat
p_add_proto_data(wmem_file_scope(), pinfo, proto_modbus, 0, request_info);
/* Continue with dissection of Modbus data payload following Modbus RTU frame */
- if( tvb_length_remaining(tvb, offset) > 0 )
+ if( tvb_reported_length_remaining(tvb, offset) > 0 )
call_dissector(modbus_handle, next_tvb, pinfo, tree);
p_remove_proto_data(wmem_file_scope(), pinfo, proto_modbus, 0);
@@ -887,7 +887,7 @@ dissect_modbus(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _
guint16 diagnostic_code;
modbus_request_info_t *request_info;
- len = tvb_length_remaining(tvb, 0);
+ len = tvb_captured_length(tvb);
/* If the packet is zero-length, we should not attempt to dissect any further */
if (len == 0)