diff options
author | Evan Huus <eapache@gmail.com> | 2015-06-22 09:59:50 -0700 |
---|---|---|
committer | Evan Huus <eapache@gmail.com> | 2015-06-22 20:43:34 +0000 |
commit | be6fb606915f4ccc68a62195619d176cd62f79f9 (patch) | |
tree | edd4b63c557923d1196dd779ac91ee1e1bae90ef /epan/dissectors/packet-uts.c | |
parent | 45872b9f7bf10476e48187f4b699c6f44943f22a (diff) |
Remove a bunch of deprecated tvb_length calls
Change-Id: I9362e0fdc4519ba5f3d656152966e7030f478839
Reviewed-on: https://code.wireshark.org/review/9022
Petri-Dish: Evan Huus <eapache@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Evan Huus <eapache@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-uts.c')
-rw-r--r-- | epan/dissectors/packet-uts.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/epan/dissectors/packet-uts.c b/epan/dissectors/packet-uts.c index 78c715541d..468ca975eb 100644 --- a/epan/dissectors/packet-uts.c +++ b/epan/dissectors/packet-uts.c @@ -73,7 +73,7 @@ static int testchar(tvbuff_t *tvb, packet_info *pinfo _U_, int offset, int op, g { gchar temp; - if (tvb_length_remaining(tvb, offset)) { + if (tvb_bytes_exist(tvb, offset, 1)) { temp = tvb_get_guint8(tvb, offset) & 0x7f; if (op == FETCH || (op == MATCH && temp == match)) { if (storage != NULL) @@ -236,7 +236,7 @@ dissect_uts(tvbuff_t *tvb, packet_info *pinfo _U_ , proto_tree *tree) } } - while (tvb_length_remaining(tvb, offset) > 0) { /* now look for the ETX */ + while (tvb_reported_length_remaining(tvb, offset) > 0) { /* now look for the ETX */ if ((tvb_get_guint8(tvb, offset) & 0x7f) == ETX) { if (header_length == -1) header_length = offset; /* the header ends at an STX, or if not found, the ETX */ @@ -246,7 +246,7 @@ dissect_uts(tvbuff_t *tvb, packet_info *pinfo _U_ , proto_tree *tree) } offset++; } - if (tvb_length_remaining(tvb, offset)) /* if there is anything left, it could be the BCC and pads */ + if (tvb_reported_length_remaining(tvb, offset)) /* if there is anything left, it could be the BCC and pads */ bcc_start = offset; if (tree) { @@ -297,7 +297,7 @@ dissect_uts(tvbuff_t *tvb, packet_info *pinfo _U_ , proto_tree *tree) if (stx_start) { proto_tree_add_protocol_format(uts_header_tree, proto_uts, tvb, stx_start, 1, "Start of Text"); - length = tvb_length_remaining(tvb, stx_start+1); /* find out how much message remains */ + length = tvb_captured_length_remaining(tvb, stx_start+1); /* find out how much message remains */ if (etx_start) length = (etx_start - stx_start - 1); /* and the data part is the rest... */ /* whatever preceeds the ETX if it exists */ |