aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-dnp.c
diff options
context:
space:
mode:
authorDario Lombardo <lomato@gmail.com>2014-06-17 17:45:00 +0200
committerAnders Broman <a.broman58@gmail.com>2014-06-18 14:14:58 +0000
commit246fe2ca4c67d8c98caa84e2f57694f6322e2f96 (patch)
tree5f8651517a3423cce11c50e18371d8a73c3c7665 /epan/dissectors/packet-dnp.c
parent971ffd683ea23362bd8009567ff7860371e6e2cc (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-dnp.c')
-rw-r--r--epan/dissectors/packet-dnp.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/epan/dissectors/packet-dnp.c b/epan/dissectors/packet-dnp.c
index d915f08af6..94b640f438 100644
--- a/epan/dissectors/packet-dnp.c
+++ b/epan/dissectors/packet-dnp.c
@@ -1813,7 +1813,7 @@ dnp3_al_process_object(tvbuff_t *tvb, packet_info *pinfo, int offset,
if (num_items < 0) {
proto_item_append_text(range_item, " (bogus)");
expert_add_info(pinfo, range_item, &ei_dnp_num_items_neg);
- return tvb_length(tvb);
+ return tvb_captured_length(tvb);
}
@@ -2788,7 +2788,7 @@ dnp3_al_process_object(tvbuff_t *tvb, packet_info *pinfo, int offset,
proto_tree_add_text(object_tree, tvb, offset, -1,
"Unknown Data Chunk, %u Bytes", tvb_reported_length_remaining(tvb, offset));
- offset = tvb_length(tvb); /* Finish decoding if unknown object is encountered... */
+ offset = tvb_captured_length(tvb); /* Finish decoding if unknown object is encountered... */
break;
}
/* Increment the bit index for next time */
@@ -2799,7 +2799,7 @@ dnp3_al_process_object(tvbuff_t *tvb, packet_info *pinfo, int offset,
}
if (start_offset > offset) {
expert_add_info(pinfo, point_item, &ei_dnp_invalid_length);
- offset = tvb_length(tvb); /* Finish decoding if unknown object is encountered... */
+ offset = tvb_captured_length(tvb); /* Finish decoding if unknown object is encountered... */
}
}
}
@@ -2824,7 +2824,7 @@ dissect_dnp3_al(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
nstime_set_zero (&al_cto);
- data_len = tvb_length(tvb);
+ data_len = tvb_captured_length(tvb);
/* Handle the control byte and function code */
al_ctl = tvb_get_guint8(tvb, offset);
@@ -3398,7 +3398,7 @@ dissect_dnp3_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void*
}
}
- return tvb_length(tvb);
+ return tvb_captured_length(tvb);
}
static guint
@@ -3423,7 +3423,7 @@ get_dnp3_message_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
static gboolean
dissect_dnp3_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
{
- gint length = tvb_length(tvb);
+ gint length = tvb_captured_length(tvb);
/* Check for a dnp packet. It should begin with 0x0564 */
if ((length < 2) || (tvb_get_ntohs(tvb, 0) != 0x0564)) {
@@ -3440,7 +3440,7 @@ dissect_dnp3_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data
static gboolean
dissect_dnp3_udp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
{
- gint length = tvb_length(tvb);
+ gint length = tvb_captured_length(tvb);
/* Check for a dnp packet. It should begin with 0x0564 */
if ((length < 2) || (tvb_get_ntohs(tvb, 0) != 0x0564)) {