Don't pass string-related encoding flags to get_uint_value() when handling
FT_UINT_STRING fields. This was causing all such fields with non-ASCII
encodings to use little-endian encoding, even when OR-ed with ENC_BIG_ENDIAN.

(not actually the topic of the above bug, but discovered during LLRP protocol
 testing, which was the topic of the above bug)

svn path=/trunk/; revision=44619
This commit is contained in:
Evan Huus 2012-08-23 02:48:26 +00:00
parent dd49262089
commit 2af3ce88bd
1 changed files with 1 additions and 1 deletions

View File

@ -1567,7 +1567,7 @@ proto_tree_new_item(field_info *new_fi, proto_tree *tree,
*/
if (encoding == TRUE)
encoding = ENC_ASCII|ENC_LITTLE_ENDIAN;
n = get_uint_value(tree, tvb, start, length, encoding);
n = get_uint_value(tree, tvb, start, length, encoding & ~ENC_CHARENCODING_MASK);
proto_tree_set_string_tvb(new_fi, tvb, start + length, n,
encoding);