[Thrift] Fix a copy-paste-o and add dissecton of T_BYTE

Change-Id: I2623d273a39393533c10568ef2f7642c05ac636c
Reviewed-on: https://code.wireshark.org/review/8311
Reviewed-by: Anders Broman <a.broman58@gmail.com>
This commit is contained in:
AndersBroman 2015-05-06 15:52:21 +02:00 committed by Anders Broman
parent 67da8aeda1
commit 0e3d53aad8
1 changed files with 13 additions and 2 deletions

View File

@ -50,6 +50,7 @@ static int hf_thrift_i32 = -1;
static int hf_thrift_utf7str = -1;
static int hf_thrift_num_list_item = -1;
static int hf_thrift_bool = -1;
static int hf_thrift_byte = -1;
static int hf_thrift_i64 = -1;
static int hf_thrift_u64 = -1;
static int hf_thrift_double = -1;
@ -171,6 +172,11 @@ dissect_thrift_type(tvbuff_t* tvb, packet_info* pinfo _U_, proto_tree* tree, int
proto_tree_add_item(tree, hf_thrift_bool, tvb, offset, 1, ENC_BIG_ENDIAN);
offset += 1;
break;
case 3:
/*T_BYTE , T_I08*/
proto_tree_add_item(tree, hf_thrift_byte, tvb, offset, 1, ENC_BIG_ENDIAN);
offset += 1;
break;
case 4:
/*T_DOUBLE*/
proto_tree_add_item(tree, hf_thrift_double, tvb, offset, 8, ENC_BIG_ENDIAN);
@ -188,12 +194,12 @@ dissect_thrift_type(tvbuff_t* tvb, packet_info* pinfo _U_, proto_tree* tree, int
break;
case 9:
/*T_U64 Integer 64*/
proto_tree_add_item(tree, hf_thrift_u64, tvb, offset, 4, ENC_BIG_ENDIAN);
proto_tree_add_item(tree, hf_thrift_u64, tvb, offset, 8, ENC_BIG_ENDIAN);
offset += 8;
break;
case 10:
/*T_I64 Integer 64*/
proto_tree_add_item(tree, hf_thrift_i64, tvb, offset, 4, ENC_BIG_ENDIAN);
proto_tree_add_item(tree, hf_thrift_i64, tvb, offset, 8, ENC_BIG_ENDIAN);
offset += 8;
break;
case 11:
@ -385,6 +391,11 @@ void proto_register_thrift(void) {
FT_UINT8, BASE_DEC, VALS(thrift_bool_vals), 0x0,
NULL, HFILL }
},
{ &hf_thrift_byte,
{ "Byte", "thrift.byte",
FT_UINT8, BASE_DEC, NULL, 0x0,
NULL, HFILL }
},
{ &hf_thrift_i64,
{ "Integer64", "thrift.i64",
FT_INT64, BASE_DEC, NULL, 0x0,