witness: FIX for tvb_get_unicode_string -> tvb_get_string_enc
authorGregor Beck <gbeck@sernet.de>
Wed, 22 Jan 2014 12:36:28 +0000 (13:36 +0100)
committerStefan Metzmacher <metze@samba.org>
Wed, 29 Jan 2014 08:18:30 +0000 (09:18 +0100)
epan/dissectors/packet-dcerpc-witness.c
epan/dissectors/pidl/witness.cnf

index 1e554ebf1b3255c1c3e80bdaa27abf09a8294166..822a729423e2da9589aaf24cb690e750f4091823 100644 (file)
@@ -252,7 +252,7 @@ static int witness_dissect_resource_change(tvbuff_t *tvb, int offset, packet_inf
        type = tvb_get_letohl(tvb, offset);
        proto_tree_add_item(tr, hf_witness_change_type, tvb, offset, 4, ENC_LITTLE_ENDIAN);
        offset += 4;
-       name = tvb_get_unicode_string(wmem_packet_scope(), tvb, offset, length-8, ENC_LITTLE_ENDIAN);
+       name = tvb_get_string_enc(wmem_packet_scope(), tvb, offset, length-8, ENC_UTF_16|ENC_LITTLE_ENDIAN);
        proto_tree_add_string(tr, hf_witness_change_name, tvb, offset, length-8, name);
        proto_item_append_text(ti, ": %s -> %s", name,
                               val_to_str(type, witness_change_type_vals,
index 6fc73c8299cc026d384bad8c4ff38cfc88d51a22..d35ac8592acfe43b374531c43827f3eb9cf9fe31 100644 (file)
@@ -143,7 +143,7 @@ static int witness_dissect_resource_change(tvbuff_t *tvb, int offset, packet_inf
        proto_tree_add_item(tr, hf_witness_change_type, tvb, offset, 4, ENC_LITTLE_ENDIAN);
        offset += 4;
 
-       name = tvb_get_unicode_string(wmem_packet_scope(), tvb, offset, length-8, ENC_LITTLE_ENDIAN);
+       name = tvb_get_string_enc(wmem_packet_scope(), tvb, offset, length-8, ENC_UTF_16|ENC_LITTLE_ENDIAN);
        proto_tree_add_string(tr, hf_witness_change_name, tvb, offset, length-8, name);
 
        proto_item_append_text(ti, ": %s -> %s", name,