Fix r35690: tvb_get_unicode_string() takes length in 8-bit bytes, not
authorsfisher <sfisher@f5534014-38df-0310-8fa8-9805f1628bb7>
Fri, 28 Jan 2011 20:12:12 +0000 (20:12 +0000)
committersfisher <sfisher@f5534014-38df-0310-8fa8-9805f1628bb7>
Fri, 28 Jan 2011 20:12:12 +0000 (20:12 +0000)
16-bit UTF-16 characters as tvb_fake_unicode() did.

git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@35691 f5534014-38df-0310-8fa8-9805f1628bb7

epan/dissectors/dcerpc/drsuapi/packet-dcerpc-drsuapi-template.c
epan/dissectors/packet-dcerpc-drsuapi.c

index 0201c5164ef505ac5f74615f7ad1d631d02fc3ae..973f24a8fe7ae334a2dda2b11a3d7cb71c99edd5 100644 (file)
@@ -72,7 +72,7 @@ ucarray_drsuapi_dissect_DsReplicaSyncRequest1Info_nc_dn(tvbuff_t *tvb, int offse
 
        ALIGN_TO_2_BYTES;
 
-       s = tvb_get_unicode_string(tvb, offset, len, ENC_LITTLE_ENDIAN);
+       s = tvb_get_unicode_string(tvb, offset, len*2, ENC_LITTLE_ENDIAN);
         if (tree && len) {
             hfinfo = proto_registrar_get_nth(hf_drsuapi_DsReplicaSyncRequest1Info_nc_dn);
             if (hfinfo->type == FT_STRING) {
index b7627592ff1b433f01d232ec9e761094dab2798d..3eb7c5b0c3f6f0862b7466d721a198dc1b569282 100644 (file)
@@ -574,7 +574,7 @@ ucarray_drsuapi_dissect_DsReplicaSyncRequest1Info_nc_dn(tvbuff_t *tvb, int offse
 
        ALIGN_TO_2_BYTES;
 
-       s = tvb_get_unicode_string(tvb, offset, len, ENC_LITTLE_ENDIAN);
+       s = tvb_get_unicode_string(tvb, offset, len*2, ENC_LITTLE_ENDIAN);
         if (tree && len) {
             hfinfo = proto_registrar_get_nth(hf_drsuapi_DsReplicaSyncRequest1Info_nc_dn);
             if (hfinfo->type == FT_STRING) {