提交 ec910641 编写于 作者: M Michal Privoznik

wireshark: Adapt to tvb_new_subset() rename

In Wireshark commit of 7cd6906056922e4b8 (contained in v2.4.0)
the tvb_new_subset() function was renamed to
tvb_new_subset_length_caplen(). However, we can take the extra
step and rename to tvb_new_subset_remaining() directly (see
Wireshark commit 0ecfc7280cf3d7). The reasoning is that there is
no other protocol in the packet than libvirt. Therefore, from the
point that libvirt dissector takes over till the end of the
packet it's all libvirt packet.
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
Reviewed-by: NMartin Kletzander <mkletzan@redhat.com>
上级 d2f6bebf
...@@ -313,7 +313,12 @@ dissect_libvirt_payload_xdr_data(tvbuff_t *tvb, proto_tree *tree, gint payload_l ...@@ -313,7 +313,12 @@ dissect_libvirt_payload_xdr_data(tvbuff_t *tvb, proto_tree *tree, gint payload_l
payload_length -= 4; payload_length -= 4;
} }
#if WIRESHARK_VERSION < 200400
payload_tvb = tvb_new_subset(tvb, start, -1, payload_length); payload_tvb = tvb_new_subset(tvb, start, -1, payload_length);
#else
payload_tvb = tvb_new_subset_remaining(tvb, start);
#endif
#if WIRESHARK_VERSION < 1012000 #if WIRESHARK_VERSION < 1012000
payload_data = (caddr_t)tvb_memdup(payload_tvb, 0, payload_length); payload_data = (caddr_t)tvb_memdup(payload_tvb, 0, payload_length);
#else #else
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册