]> xenbits.xensource.com Git - libvirt.git/commitdiff
wireshark: s/tvb_length/tvb_captured_length/
authorMichal Privoznik <mprivozn@redhat.com>
Sun, 27 Dec 2015 09:55:29 +0000 (10:55 +0100)
committerMichal Privoznik <mprivozn@redhat.com>
Mon, 11 Jan 2016 16:23:41 +0000 (17:23 +0100)
In wireshak commit 22149c55 (v.1.11.3) the API was renamed.
Follow the change in our code too. Since the wireshark change was
made in the very same version that we require at least we are
good to go.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
tools/wireshark/src/packet-libvirt.c

index f7c8e0c2888fbf2828302584fb62e28c3ca1ae9c..d0b0852f01cce1b5e4d7f0a9d0b48e8bb26779cc 100644 (file)
@@ -338,7 +338,7 @@ dissect_libvirt_payload(tvbuff_t *tvb, proto_tree *tree,
 {
     gssize payload_length;
 
-    payload_length = tvb_length(tvb) - VIR_HEADER_LEN;
+    payload_length = tvb_captured_length(tvb) - VIR_HEADER_LEN;
     if (payload_length <= 0)
         return; /* No payload */
 
@@ -405,7 +405,7 @@ dissect_libvirt_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
         proto_item *ti;
         proto_tree *libvirt_tree;
 
-        ti = proto_tree_add_item(tree, proto_libvirt, tvb, 0, tvb_length(tvb), ENC_NA);
+        ti = proto_tree_add_item(tree, proto_libvirt, tvb, 0, tvb_captured_length(tvb), ENC_NA);
         libvirt_tree = proto_item_add_subtree(ti, ett_libvirt);
 
         offset = 0;