aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-6lowpan.c
diff options
context:
space:
mode:
authorAndersBroman <a.broman@bredband.net>2015-04-14 08:55:47 +0200
committerAnders Broman <a.broman58@gmail.com>2015-04-14 06:58:40 +0000
commit870d223b69c962902778baeabbe952f560a27426 (patch)
treec2181fcceb1ec3f42acc3fd0c35e837a0be861fa /epan/dissectors/packet-6lowpan.c
parent62c0e032e062c6e3d932d311bcca9f281ade27f4 (diff)
Change deprecated API tvb_length -> tvb_reported_length
Change-Id: I14577dccaed5aa5ed85e94b6810a94b4c8b2e437 Reviewed-on: https://code.wireshark.org/review/8059 Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-6lowpan.c')
-rw-r--r--epan/dissectors/packet-6lowpan.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/epan/dissectors/packet-6lowpan.c b/epan/dissectors/packet-6lowpan.c
index b507b54ad1..42cdec82e1 100644
--- a/epan/dissectors/packet-6lowpan.c
+++ b/epan/dissectors/packet-6lowpan.c
@@ -1323,7 +1323,7 @@ dissect_6lowpan_hc1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gint dg
/* Construct the next header for the UDP datagram. */
offset = BITS_TO_BYTE_LEN(0, bit_offset);
- length = (gint)tvb_ensure_length_remaining(tvb, offset);
+ length = (gint)tvb_ensure_captured_length_remaining(tvb, offset);
nhdr_list = (struct lowpan_nhdr *)wmem_alloc(wmem_packet_scope(), sizeof(struct lowpan_nhdr) + sizeof(struct udp_hdr) + length);
nhdr_list->next = NULL;
nhdr_list->proto = IP_PROTO_UDP;
@@ -1341,7 +1341,7 @@ dissect_6lowpan_hc1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gint dg
else {
gint length;
offset = BITS_TO_BYTE_LEN(0, bit_offset);
- length = (gint)tvb_ensure_length_remaining(tvb, offset);
+ length = (gint)tvb_ensure_captured_length_remaining(tvb, offset);
nhdr_list = (struct lowpan_nhdr *)wmem_alloc(wmem_packet_scope(), sizeof(struct lowpan_nhdr) + length);
nhdr_list->next = NULL;
nhdr_list->proto = ipv6.ip6_nxt;
@@ -1771,7 +1771,7 @@ dissect_6lowpan_iphc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gint d
}
/* Create an extension header for the remaining payload. */
else {
- length = (gint)tvb_ensure_length_remaining(tvb, offset);
+ length = (gint)tvb_ensure_captured_length_remaining(tvb, offset);
nhdr_list = (struct lowpan_nhdr *)wmem_alloc(wmem_packet_scope(), sizeof(struct lowpan_nhdr) + length);
nhdr_list->next = NULL;
nhdr_list->proto = ipv6.ip6_nxt;
@@ -1959,7 +1959,7 @@ dissect_6lowpan_iphc_nhc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gi
}
else {
/* Create another next header structure for the remaining payload. */
- length = (gint)tvb_ensure_length_remaining(tvb, offset);
+ length = (gint)tvb_ensure_captured_length_remaining(tvb, offset);
nhdr->next = (struct lowpan_nhdr *)wmem_alloc(wmem_packet_scope(), sizeof(struct lowpan_nhdr) + length);
nhdr->next->next = NULL;
nhdr->next->proto = ipv6_ext.ip6e_nxt;
@@ -2108,7 +2108,7 @@ dissect_6lowpan_iphc_nhc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gi
#endif
/* Create the next header structure for the UDP datagram. */
- length = (gint)tvb_ensure_length_remaining(tvb, offset);
+ length = (gint)tvb_ensure_captured_length_remaining(tvb, offset);
nhdr = (struct lowpan_nhdr *)wmem_alloc(wmem_packet_scope(), sizeof(struct lowpan_nhdr) + sizeof(struct udp_hdr) + length);
nhdr->next = NULL;
nhdr->proto = IP_PROTO_UDP;