diff options
author | AndersBroman <a.broman@bredband.net> | 2015-04-15 17:20:35 +0200 |
---|---|---|
committer | Anders Broman <a.broman58@gmail.com> | 2015-04-15 15:22:42 +0000 |
commit | 05c0152370cbe084193ad2946e6fc96a1017c08e (patch) | |
tree | 3214e835a86507969b9cf0a93391fcaa51e56c3a /epan/dissectors/packet-bittorrent.c | |
parent | d2e880eab134e4414b143b6e03767bf6424b749c (diff) |
Replcae deprecated API tvb_length with tvb_reported_length or tvb_captured
length.
Change-Id: Id42f3409a32e202528d350f7afde7376e411fc51
Reviewed-on: https://code.wireshark.org/review/8076
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-bittorrent.c')
-rw-r--r-- | epan/dissectors/packet-bittorrent.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/epan/dissectors/packet-bittorrent.c b/epan/dissectors/packet-bittorrent.c index 0cdb7688cc..3019312124 100644 --- a/epan/dissectors/packet-bittorrent.c +++ b/epan/dissectors/packet-bittorrent.c @@ -291,7 +291,7 @@ get_bittorrent_pdu_length(packet_info *pinfo _U_, tvbuff_t *tvb, data from the middle of a message, and just return the remaining length in the tvbuff so the rest of the tvbuff is displayed as continuation data. */ - return tvb_length_remaining(tvb, offset); + return tvb_reported_length_remaining(tvb, offset); } } else { /* We don't have the type field, so we can't determine @@ -300,7 +300,7 @@ get_bittorrent_pdu_length(packet_info *pinfo _U_, tvbuff_t *tvb, and just return the remaining length in the tvbuff so the rest of the tvbuff is displayed as continuation data. */ - return tvb_length_remaining(tvb, offset); + return tvb_reported_length_remaining(tvb, offset); } } } @@ -547,7 +547,7 @@ int dissect_bittorrent_tcp_pdu (tvbuff_t *tvb, packet_info *pinfo, proto_tree *t col_append_str(pinfo->cinfo, COL_INFO, " "); col_set_fence(pinfo->cinfo, COL_INFO); - return tvb_length(tvb); + return tvb_reported_length(tvb); } static @@ -555,7 +555,7 @@ int dissect_bittorrent (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, voi { tcp_dissect_pdus(tvb, pinfo, tree, bittorrent_desegment, BITTORRENT_HEADER_LENGTH, get_bittorrent_pdu_length, dissect_bittorrent_tcp_pdu, data); - return tvb_length(tvb); + return tvb_reported_length(tvb); } static @@ -564,7 +564,7 @@ gboolean test_bittorrent_packet (tvbuff_t *tvb, packet_info *pinfo, { conversation_t *conversation; - if (tvb_length(tvb) >= 20 && + if (tvb_captured_length(tvb) >= 20 && tvb_get_guint8(tvb, 0) == 19 && tvb_memeql(tvb, 1, "BitTorrent protocol", 19) == 0) { conversation = find_or_create_conversation(pinfo); |