From d7fe514fc05e95e3a99fd211768de5abdc3f6486 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sun, 18 Sep 2016 18:48:50 -0700 Subject: Improve support for single-character fields and filter expressions. Add an FT_CHAR type, which is like FT_UINT8 except that the value is displayed as a C-style character constant. Allow use of C-style character constants in filter expressions; they can be used in comparisons with all integral types, and in "contains" operators. Use that type for some fields that appear (based on the way they're displayed, or on the use of C-style character constants in their value_string tables) to be 1-byte characters rather than 8-bit numbers. Change-Id: I39a9f0dda0bd7f4fa02a9ca8373216206f4d7135 Reviewed-on: https://code.wireshark.org/review/17787 Reviewed-by: Guy Harris --- plugins/profinet/packet-dcerpc-pn-io.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'plugins') diff --git a/plugins/profinet/packet-dcerpc-pn-io.c b/plugins/profinet/packet-dcerpc-pn-io.c index 490bb547bf..f1f98d43f4 100644 --- a/plugins/profinet/packet-dcerpc-pn-io.c +++ b/plugins/profinet/packet-dcerpc-pn-io.c @@ -3413,7 +3413,7 @@ dissect_IandM0_block(tvbuff_t *tvb, int offset, offset = dissect_dcerpc_uint16(tvb, offset, pinfo, tree, drep, hf_pn_io_im_hardware_revision, &u16IMHardwareRevision); /* c8 SWRevisionPrefix */ - offset = dissect_dcerpc_uint8(tvb, offset, pinfo, tree, drep, + offset = dissect_dcerpc_char(tvb, offset, pinfo, tree, drep, hf_pn_io_im_revision_prefix, &u8SWRevisionPrefix); /* x8 IM_SWRevision_Functional_Enhancement */ offset = dissect_dcerpc_uint8(tvb, offset, pinfo, tree, drep, @@ -12335,7 +12335,7 @@ proto_register_pn_io (void) /* XXX - better use a simple char here -> vals */ { &hf_pn_io_im_revision_prefix, { "IMRevisionPrefix", "pn_io.im_revision_prefix", - FT_UINT8, BASE_HEX, VALS(pn_io_im_revision_prefix_vals), 0x0, + FT_CHAR, BASE_HEX, VALS(pn_io_im_revision_prefix_vals), 0x0, NULL, HFILL } }, { &hf_pn_io_im_sw_revision_functional_enhancement, -- cgit v1.2.3