diff options
Diffstat (limited to 'epan/dissectors/packet-cmp.c')
-rw-r--r-- | epan/dissectors/packet-cmp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/epan/dissectors/packet-cmp.c b/epan/dissectors/packet-cmp.c index 800cdea1e9..2c2bd1ccab 100644 --- a/epan/dissectors/packet-cmp.c +++ b/epan/dissectors/packet-cmp.c @@ -1558,7 +1558,7 @@ static int dissect_cmp_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *pa switch(pdu_type){ case CMP_TYPE_PKIMSG: - next_tvb = tvb_new_subset(tvb, offset, tvb_reported_length_remaining(tvb, offset), pdu_len); + next_tvb = tvb_new_subset_length_caplen(tvb, offset, tvb_reported_length_remaining(tvb, offset), pdu_len); dissect_cmp_pdu(next_tvb, tree, &asn1_ctx); offset += tvb_reported_length_remaining(tvb, offset); break; @@ -1586,12 +1586,12 @@ static int dissect_cmp_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *pa proto_tree_add_time(tcptrans_tree, hf_cmp_tcptrans_ttcb, tvb, offset, 4, &ts); offset += 4; - next_tvb = tvb_new_subset(tvb, offset, tvb_reported_length_remaining(tvb, offset), pdu_len); + next_tvb = tvb_new_subset_length_caplen(tvb, offset, tvb_reported_length_remaining(tvb, offset), pdu_len); dissect_cmp_pdu(next_tvb, tree, &asn1_ctx); offset += tvb_reported_length_remaining(tvb, offset); break; case CMP_TYPE_FINALMSGREP: - next_tvb = tvb_new_subset(tvb, offset, tvb_reported_length_remaining(tvb, offset), pdu_len); + next_tvb = tvb_new_subset_length_caplen(tvb, offset, tvb_reported_length_remaining(tvb, offset), pdu_len); dissect_cmp_pdu(next_tvb, tree, &asn1_ctx); offset += tvb_reported_length_remaining(tvb, offset); break; |