diff options
author | Guy Harris <guy@alum.mit.edu> | 2017-01-09 22:40:07 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2017-01-10 06:40:45 +0000 |
commit | 0ecfc7280cf3d793a754722b27692216e5a2986f (patch) | |
tree | fb55970128be57397b9d2beea83cf5fa993497c9 /epan/dissectors/packet-c15ch.c | |
parent | 7cd6906056922e4b8f68f1216d94eaa0809896fe (diff) |
Use tvb_new_subset_remaining() rather than tvb_new_subset_length_caplen().
Any call of the form tvb_new_subset_length_caplen(tvb, offset, -1, -1)
should instead be tvb_new_subset_remaining(tvb, offset).
Change-Id: I4bc95b028103ea4fc82453ef3460c147d7ccabd6
Reviewed-on: https://code.wireshark.org/review/19598
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/dissectors/packet-c15ch.c')
-rw-r--r-- | epan/dissectors/packet-c15ch.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/epan/dissectors/packet-c15ch.c b/epan/dissectors/packet-c15ch.c index cc5afedcf5..87cfbd0190 100644 --- a/epan/dissectors/packet-c15ch.c +++ b/epan/dissectors/packet-c15ch.c @@ -5978,7 +5978,7 @@ static int dissect_c15ch_inc_gwe(tvbuff_t *tvb, packet_info *pinfo, proto_tree * proto_tree_add_item(c15ch_inc_gwe_tree, hf_c15ch_inc_gwe_datatype, tvb, 10, 1, ENC_BIG_ENDIAN); } - next_tvb = tvb_new_subset_length_caplen(tvb, 11, -1, -1); + next_tvb = tvb_new_subset_remaining(tvb, 11); /*third level dissection*/ retv = 11 + dissector_try_uint(c15ch_inc_gwe_dissector_table, type_num, next_tvb, pinfo, tree); return retv; @@ -6641,7 +6641,7 @@ static int dissect_c15ch_out_gwe(tvbuff_t *tvb, packet_info *pinfo, proto_tree * proto_tree_add_item(c15ch_out_gwe_tree, hf_c15ch_out_gwe_gwe_data_type, tvb, 14, 1, ENC_BIG_ENDIAN); } - next_tvb = tvb_new_subset_length_caplen(tvb, 15, -1, -1); + next_tvb = tvb_new_subset_remaining(tvb, 15); dissector_try_uint(c15ch_out_gwe_dissector_table, data_type, next_tvb, pinfo, tree); return tvb_reported_length(tvb); @@ -7208,7 +7208,7 @@ static int dissect_c15ch_tone(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tre proto_tree_add_item(c15ch_tone_tree, hf_c15ch_tone_msg_type, tvb, 0, 1, ENC_BIG_ENDIAN); } - next_tvb = tvb_new_subset_length_caplen(tvb, 1, -1, -1); + next_tvb = tvb_new_subset_remaining(tvb, 1); retv = 1 + dissector_try_uint(c15ch_tone_dissector_table, msg_type, next_tvb, pinfo, tree); return retv; } |