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-smpp.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-smpp.c')
-rw-r--r-- | epan/dissectors/packet-smpp.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/epan/dissectors/packet-smpp.c b/epan/dissectors/packet-smpp.c index 5ae1054583..606ba21bc4 100644 --- a/epan/dissectors/packet-smpp.c +++ b/epan/dissectors/packet-smpp.c @@ -2411,7 +2411,7 @@ dissect_smpp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data) guint32 offset = 0; while (tvb_reported_length_remaining(tvb, offset) > 0) { guint16 pdu_len = tvb_get_ntohl(tvb, offset); - gint pdu_real_len = tvb_length_remaining(tvb, offset); + gint pdu_real_len = tvb_captured_length_remaining(tvb, offset); tvbuff_t *pdu_tvb; if (pdu_len < 1) @@ -2428,7 +2428,7 @@ dissect_smpp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data) } } - return tvb_length(tvb); + return tvb_captured_length(tvb); } @@ -2486,7 +2486,7 @@ dissect_smpp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data * Create display subtree for the protocol */ if (tree) { - ti = proto_tree_add_item (tree, proto_smpp, tvb, 0, tvb_length(tvb), ENC_NA); + ti = proto_tree_add_item (tree, proto_smpp, tvb, 0, tvb_captured_length(tvb), ENC_NA); smpp_tree = proto_item_add_subtree (ti, ett_smpp); } @@ -2524,13 +2524,13 @@ dissect_smpp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data * Physical length: at most command_length * Reported length: command_length */ - if (tvb_length_remaining(tvb, offset - 16 + command_length) > 0) { + if (tvb_captured_length_remaining(tvb, offset - 16 + command_length) > 0) { pdu_tvb = tvb_new_subset(tvb, offset - 16, command_length, /* Physical length */ command_length); /* Length reported by the protocol */ } else { pdu_tvb = tvb_new_subset(tvb, offset - 16, - tvb_length_remaining(tvb, offset - 16),/* Physical length */ + tvb_captured_length_remaining(tvb, offset - 16),/* Physical length */ command_length); /* Length reported by the protocol */ } @@ -2729,7 +2729,7 @@ dissect_smpp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data first = FALSE; } - return tvb_length(tvb); + return tvb_captured_length(tvb); } |