From 198c9ba55f51c33123b84c2c92a070c8192f8589 Mon Sep 17 00:00:00 2001 From: Bill Meier Date: Fri, 16 Mar 2012 02:00:29 +0000 Subject: FT_BOOLEAN hf[] entries with a 0 'bitmask' should have 'display' = BASE_NONE; In some cases: Use val_to_str_const() instead of val_to_str(); Reformat long lines; Do some general whitespace changes. svn path=/trunk/; revision=41587 --- epan/dissectors/packet-catapult-dct2000.c | 131 +++++++++++------------ epan/dissectors/packet-dmp.c | 4 +- epan/dissectors/packet-enip.c | 2 +- epan/dissectors/packet-erf.c | 4 +- epan/dissectors/packet-gsm_a_dtap.c | 2 +- epan/dissectors/packet-gsm_a_gm.c | 170 +++++++++++++++--------------- epan/dissectors/packet-ieee80211.c | 10 +- epan/dissectors/packet-ieee802154.c | 26 ++--- epan/dissectors/packet-kerberos.c | 2 +- epan/dissectors/packet-mac-lte.c | 80 +++++++------- epan/dissectors/packet-opensafety.c | 134 +++++++++++------------ epan/dissectors/packet-rtmpt.c | 53 +++++----- epan/dissectors/packet-vnc.c | 54 +++++----- 13 files changed, 338 insertions(+), 334 deletions(-) (limited to 'epan/dissectors') diff --git a/epan/dissectors/packet-catapult-dct2000.c b/epan/dissectors/packet-catapult-dct2000.c index f1db29c19b..41ba29486d 100644 --- a/epan/dissectors/packet-catapult-dct2000.c +++ b/epan/dissectors/packet-catapult-dct2000.c @@ -313,7 +313,7 @@ static gboolean find_ipprim_data_offset(tvbuff_t *tvb, int *data_offset, guint8 guint16 *conn_id_offset) { guint8 length; - int offset = *data_offset; + int offset = *data_offset; /* Get the ipprim command code. */ guint8 tag = tvb_get_guint8(tvb, offset++); @@ -493,9 +493,9 @@ static gboolean find_sctpprim_variant3_data_offset(tvbuff_t *tvb, int *data_offs guint16 *dest_addr_length, guint32 *dest_port_offset) { - guint16 tag = 0; + guint16 tag = 0; guint16 length = 0; - int offset = *data_offset; + int offset = *data_offset; /* Get the sctpprim (2 byte) command code. */ guint16 top_tag = tvb_get_ntohs(tvb, offset); @@ -683,13 +683,13 @@ static void dissect_rlc_umts(tvbuff_t *tvb, gint offset, packet_info *pinfo, proto_tree *tree, gboolean is_sent) { - guint8 tag; - gboolean ueid_set = FALSE, rbid_set=FALSE; - guint32 ueid = 0; - guint8 rbid = 0; - guint8 length; - tvbuff_t *rlc_tvb; - dissector_handle_t rlc_umts_handle = 0; + guint8 tag; + gboolean ueid_set = FALSE, rbid_set=FALSE; + guint32 ueid = 0; + guint8 rbid = 0; + guint8 length; + tvbuff_t *rlc_tvb; + dissector_handle_t rlc_umts_handle = 0; /* Top-level opcode */ tag = tvb_get_guint8(tvb, offset++); @@ -820,13 +820,13 @@ static void dissect_rlc_umts(tvbuff_t *tvb, gint offset, static void dissect_rrc_lte(tvbuff_t *tvb, gint offset, packet_info *pinfo, proto_tree *tree) { - guint8 tag; - dissector_handle_t protocol_handle = 0; - gboolean isUplink = FALSE; - LogicalChannelType logicalChannelType; - guint16 cell_id; - guint8 bcch_transport = 0; - tvbuff_t *rrc_tvb; + guint8 tag; + dissector_handle_t protocol_handle = 0; + gboolean isUplink = FALSE; + LogicalChannelType logicalChannelType; + guint16 cell_id; + guint8 bcch_transport = 0; + tvbuff_t *rrc_tvb; /* Top-level opcode */ tag = tvb_get_guint8(tvb, offset++); @@ -1016,11 +1016,11 @@ static void dissect_rrc_lte(tvbuff_t *tvb, gint offset, static void dissect_ccpri_lte(tvbuff_t *tvb, gint offset, packet_info *pinfo, proto_tree *tree) { - guint8 opcode; - guint8 tag; - tvbuff_t *ccpri_tvb; - dissector_handle_t protocol_handle = 0; - guint16 length; + guint8 opcode; + guint8 tag; + tvbuff_t *ccpri_tvb; + dissector_handle_t protocol_handle = 0; + guint16 length; /* Top-level opcode */ proto_tree_add_item(tree, hf_catapult_dct2000_lte_ccpri_opcode, tvb, offset, 1, ENC_BIG_ENDIAN); @@ -1081,12 +1081,12 @@ static void dissect_ccpri_lte(tvbuff_t *tvb, gint offset, static void dissect_pdcp_lte(tvbuff_t *tvb, gint offset, packet_info *pinfo, proto_tree *tree) { - guint8 opcode; - guint8 tag; - struct pdcp_lte_info *p_pdcp_lte_info = NULL; - tvbuff_t *pdcp_lte_tvb; - guint16 ueid; - guint8 channelId; + guint8 opcode; + guint8 tag; + struct pdcp_lte_info *p_pdcp_lte_info = NULL; + tvbuff_t *pdcp_lte_tvb; + guint16 ueid; + guint8 channelId; /* Look this up so can update channel info */ p_pdcp_lte_info = p_get_proto_data(pinfo->fd, proto_pdcp_lte); @@ -1373,7 +1373,7 @@ static dissector_handle_t look_for_dissector(const char *protocol_name) /* Populate outhdr_values array with numbers found in outhdr_string */ static void parse_outhdr_string(const guchar *outhdr_string) { - int n = 0; + int n = 0; guint outhdr_string_len = (guint)strlen((const gchar*)outhdr_string); /* Populate values array */ @@ -1613,8 +1613,9 @@ static void attach_fp_info(packet_info *pinfo, gboolean received, const char *pr static void attach_rlc_info(packet_info *pinfo, guint32 urnti, guint8 rbid, gboolean is_sent) { /* Only need to set info once per session. */ - struct fp_info *p_fp_info = p_get_proto_data(pinfo->fd, proto_fp); + struct fp_info *p_fp_info = p_get_proto_data(pinfo->fd, proto_fp); struct rlc_info *p_rlc_info = p_get_proto_data(pinfo->fd, proto_rlc); + if (p_rlc_info != NULL) { return; } @@ -1686,7 +1687,7 @@ static void attach_rlc_info(packet_info *pinfo, guint32 urnti, guint8 rbid, gboo static void attach_mac_lte_info(packet_info *pinfo) { struct mac_lte_info *p_mac_lte_info; - unsigned int i=0; + unsigned int i = 0; /* Only need to set info once per session. */ p_mac_lte_info = get_mac_lte_proto_data(pinfo); @@ -1803,7 +1804,7 @@ static void attach_mac_lte_info(packet_info *pinfo) static void attach_rlc_lte_info(packet_info *pinfo) { struct rlc_lte_info *p_rlc_lte_info; - unsigned int i=0; + unsigned int i = 0; /* Only need to set info once per session. */ p_rlc_lte_info = p_get_proto_data(pinfo->fd, proto_rlc_lte); @@ -1832,7 +1833,7 @@ static void attach_rlc_lte_info(packet_info *pinfo) static void attach_pdcp_lte_info(packet_info *pinfo) { struct pdcp_lte_info *p_pdcp_lte_info; - unsigned int i=0; + unsigned int i = 0; /* Only need to set info once per session. */ p_pdcp_lte_info = p_get_proto_data(pinfo->fd, proto_pdcp_lte); @@ -1870,8 +1871,8 @@ static void attach_pdcp_lte_info(packet_info *pinfo) static void dissect_tty_lines(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offset) { gint next_offset; - proto_tree *tty_tree; - proto_item *ti; + proto_tree *tty_tree; + proto_item *ti; int lines = 0; /* Create tty tree. */ @@ -1933,15 +1934,15 @@ static void dissect_tty_lines(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tre static void check_for_oob_mac_lte_events(packet_info *pinfo, tvbuff_t *tvb, proto_tree *tree, const char *string) { - guint number_of_ues; - guint ueids[MAX_SRs]; - guint rntis[MAX_SRs]; - guint rapid; - guint rach_attempt_number; - mac_lte_oob_event oob_event; + guint number_of_ues; + guint ueids[MAX_SRs]; + guint rntis[MAX_SRs]; + guint rapid; + guint rach_attempt_number; + mac_lte_oob_event oob_event; struct mac_lte_info *p_mac_lte_info; - tvbuff_t *mac_lte_tvb = NULL; - guint16 n; + tvbuff_t *mac_lte_tvb = NULL; + guint16 n; /* Look for strings matching expected formats */ if (sscanf(string, ">> RACH Preamble Request[UE = %u] [RAPID = %u] [Attempt = %u]", @@ -2045,27 +2046,27 @@ static void check_for_oob_mac_lte_events(packet_info *pinfo, tvbuff_t *tvb, prot static void dissect_catapult_dct2000(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) { - proto_tree *dct2000_tree = NULL; - proto_item *ti = NULL; - gint offset = 0; - gint context_length; - const char *context_name; - guint8 port_number; - gint protocol_length; - gint timestamp_length; - const char *timestamp_string; - gint variant_length; - const char *variant_string; - gint outhdr_length; - const char *outhdr_string; - guint8 direction; - tvbuff_t *next_tvb; - int encap; - dissector_handle_t protocol_handle = 0; - dissector_handle_t heur_protocol_handle = 0; - int sub_dissector_result = 0; - const char *protocol_name; - gboolean is_comment; + proto_tree *dct2000_tree = NULL; + proto_item *ti = NULL; + gint offset = 0; + gint context_length; + const char *context_name; + guint8 port_number; + gint protocol_length; + gint timestamp_length; + const char *timestamp_string; + gint variant_length; + const char *variant_string; + gint outhdr_length; + const char *outhdr_string; + guint8 direction; + tvbuff_t *next_tvb; + int encap; + dissector_handle_t protocol_handle = 0; + dissector_handle_t heur_protocol_handle = 0; + int sub_dissector_result = 0; + const char *protocol_name; + gboolean is_comment; /* Set Protocol */ col_set_str(pinfo->cinfo, COL_PROTOCOL, "DCT2000"); @@ -3167,7 +3168,7 @@ void proto_register_catapult_dct2000(void) }, { &hf_catapult_dct2000_last_in_seg_set, { "Last in seg set", - "dct2000.last-in-seg-set", FT_BOOLEAN, BASE_DEC, TFS(&tfs_yes_no), 0x0, + "dct2000.last-in-seg-set", FT_BOOLEAN, BASE_NONE, TFS(&tfs_yes_no), 0x0, NULL, HFILL } }, diff --git a/epan/dissectors/packet-dmp.c b/epan/dissectors/packet-dmp.c index 06cacaa735..a541e159f5 100644 --- a/epan/dissectors/packet-dmp.c +++ b/epan/dissectors/packet-dmp.c @@ -4289,10 +4289,10 @@ void proto_register_dmp (void) { "Reporting Name Number", "dmp.reporting_name", FT_NONE, BASE_NONE, NULL, 0x0, "Reporting Name", HFILL } }, { &hf_addr_dl_expanded, - { "DL Expanded", "dmp.dl_expanded", FT_BOOLEAN, 8, + { "DL Expanded", "dmp.dl_expanded", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "Message has been DL expanded", HFILL } }, { &hf_addr_int_rec, - { "Intended Recipient", "dmp.int_rec", FT_BOOLEAN, 8, + { "Intended Recipient", "dmp.int_rec", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "Message has an intended recipient", HFILL } }, /* diff --git a/epan/dissectors/packet-enip.c b/epan/dissectors/packet-enip.c index 1bc601624a..860c5d939a 100644 --- a/epan/dissectors/packet-enip.c +++ b/epan/dissectors/packet-enip.c @@ -2154,7 +2154,7 @@ proto_register_enip(void) { &hf_tcpip_mcast_reserved, { "Reserved", "cip.tcpip.mcast.reserved", FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL }}, { &hf_tcpip_mcast_num_mcast, { "Num MCast", "cip.tcpip.mcast.num_mcast", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }}, { &hf_tcpip_mcast_addr_start, { "MCast Start Addr", "cip.tcpip.mcast.addr_start", FT_IPv4, BASE_NONE, NULL, 0, NULL, HFILL }}, - { &hf_tcpip_select_acd, { "Select ACD", "cip.tcpip.select_acd", FT_BOOLEAN, 8, TFS(&tfs_enabled_disabled), 0, NULL, HFILL }}, + { &hf_tcpip_select_acd, { "Select ACD", "cip.tcpip.select_acd", FT_BOOLEAN, BASE_NONE, TFS(&tfs_enabled_disabled), 0, NULL, HFILL }}, { &hf_tcpip_lcd_acd_activity, { "ACD Activity", "cip.tcpip.last_conflict.acd_activity", FT_UINT8, BASE_DEC, enip_tcpip_acd_activity_vals, 0, NULL, HFILL }}, { &hf_tcpip_lcd_remote_mac, { "RemoteMAC", "cip.tcpip.last_conflict.remote_mac", FT_ETHER, BASE_NONE, NULL, 0, NULL, HFILL }}, { &hf_tcpip_lcd_arp_pdu, { "Arp PDU", "cip.tcpip.last_conflict.arp_pdu", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }}, diff --git a/epan/dissectors/packet-erf.c b/epan/dissectors/packet-erf.c index b0009c94ea..f604ff6ffe 100644 --- a/epan/dissectors/packet-erf.c +++ b/epan/dissectors/packet-erf.c @@ -1616,10 +1616,10 @@ proto_register_erf(void) /* Channelised Extension Header */ { &hf_erf_ehdr_chan_morebits, { "More Bits", "erf.ehdr.chan.morebits", - FT_BOOLEAN, BASE_HEX, NULL, 0, NULL, HFILL } }, + FT_BOOLEAN, BASE_NONE, NULL, 0, NULL, HFILL } }, { &hf_erf_ehdr_chan_morefrag, { "More Fragments", "erf.ehdr.chan.morefrag", - FT_BOOLEAN, BASE_HEX, NULL, 0, NULL, HFILL } }, + FT_BOOLEAN, BASE_NONE, NULL, 0, NULL, HFILL } }, { &hf_erf_ehdr_chan_seqnum, { "Sequence Number", "erf.ehdr.chan.seqnum", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL } }, diff --git a/epan/dissectors/packet-gsm_a_dtap.c b/epan/dissectors/packet-gsm_a_dtap.c index bb5db5487c..b928c19a32 100644 --- a/epan/dissectors/packet-gsm_a_dtap.c +++ b/epan/dissectors/packet-gsm_a_dtap.c @@ -6622,7 +6622,7 @@ proto_register_gsm_a_dtap(void) }, { &hf_gsm_a_dtap_csmt, { "CSMT", "gsm_a.dtap.csmt", - FT_BOOLEAN, 8, TFS(&gsm_a_dtap_csmt_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_dtap_csmt_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_dtap_alerting_pattern, diff --git a/epan/dissectors/packet-gsm_a_gm.c b/epan/dissectors/packet-gsm_a_gm.c index 26bcc4f0f5..65f2941fc6 100644 --- a/epan/dissectors/packet-gsm_a_gm.c +++ b/epan/dissectors/packet-gsm_a_gm.c @@ -2313,7 +2313,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui oct <<= bits_needed; bits_in_oct -= bits_needed; value--; - + /* skip spare bits */ bit_offset+=value; curr_bits_length -= value; @@ -2373,7 +2373,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui /* * Release 6 */ - + /* * Multiple TBF Capability */ @@ -2384,7 +2384,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * Downlink Advanced Receiver Performance */ @@ -2395,7 +2395,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * Extended RLC/MAC Control Message Segmentation Capability */ @@ -2476,7 +2476,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui bits_in_oct -= bits_needed; } } - + /* * PS Handover Capability */ @@ -2487,11 +2487,11 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * Release 7 */ - + /* * DTM Handover Capability */ @@ -2555,7 +2555,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * GAN PS Handover Capability */ @@ -2566,7 +2566,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * RLC Non-persistent Mode */ @@ -2577,7 +2577,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * Reduced Latency Capability */ @@ -2588,7 +2588,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * Uplink EGPRS2 */ @@ -2599,7 +2599,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * Downlink EGPRS2 */ @@ -2610,11 +2610,11 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * Release 8 */ - + /* * E-UTRA FDD support */ @@ -2625,7 +2625,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * E-UTRA TDD support */ @@ -2636,7 +2636,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * GERAN to E-UTRA support in GERAN packet transfer mode */ @@ -2647,7 +2647,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * Priority-based reselection support */ @@ -2658,7 +2658,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * Release 9 */ @@ -2692,7 +2692,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui curr_bits_length -= bits_needed; oct <<= bits_needed; bits_in_oct -= bits_needed; - + /* * EFTA Multislot Capability Reduction for Downlink Dual Carrier */ @@ -2704,7 +2704,7 @@ de_gmm_ms_radio_acc_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, gui oct <<= bits_needed; bits_in_oct -= bits_needed; } - + /* * Indication of Upper Layer PDU Start Capability for RLC UM */ @@ -6484,7 +6484,7 @@ dtap_sm_req_mbms_act(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint3 guint curr_len; curr_offset = offset; - curr_len = len; + curr_len = len; pinfo->p2p_dir = P2P_DIR_SENT; @@ -6511,7 +6511,7 @@ dtap_sm_req_mbms_rej(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint3 guint curr_len; curr_offset = offset; - curr_len = len; + curr_len = len; pinfo->p2p_dir = P2P_DIR_RECV; @@ -6586,25 +6586,27 @@ static void (*dtap_msg_sm_fcn[])(tvbuff_t *tvb, proto_tree *tree, packet_info *p NULL, /* NONE */ }; -void get_gmm_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *dtap_msg_fcn) +void +get_gmm_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *dtap_msg_fcn) { gint idx; - *msg_str = match_strval_idx((guint32) (oct & DTAP_GMM_IEI_MASK), gsm_a_dtap_msg_gmm_strings, &idx); - *ett_tree = ett_gsm_dtap_msg_gmm[idx]; - *hf_idx = hf_gsm_a_dtap_msg_gmm_type; + *msg_str = match_strval_idx((guint32) (oct & DTAP_GMM_IEI_MASK), gsm_a_dtap_msg_gmm_strings, &idx); + *ett_tree = ett_gsm_dtap_msg_gmm[idx]; + *hf_idx = hf_gsm_a_dtap_msg_gmm_type; *dtap_msg_fcn = dtap_msg_gmm_fcn[idx]; return; } -void get_sm_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *dtap_msg_fcn) +void +get_sm_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *dtap_msg_fcn) { gint idx; - *msg_str = match_strval_idx((guint32) (oct & DTAP_SM_IEI_MASK), gsm_a_dtap_msg_sm_strings, &idx); - *ett_tree = ett_gsm_dtap_msg_sm[idx]; - *hf_idx = hf_gsm_a_dtap_msg_sm_type; + *msg_str = match_strval_idx((guint32) (oct & DTAP_SM_IEI_MASK), gsm_a_dtap_msg_sm_strings, &idx); + *ett_tree = ett_gsm_dtap_msg_sm[idx]; + *hf_idx = hf_gsm_a_dtap_msg_sm_type; *dtap_msg_fcn = dtap_msg_sm_fcn[idx]; return; @@ -6898,57 +6900,57 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_nsapi_5_ul_stat, { "NSAPI(5) uplink status", "gsm_a.gm.nsapi_5_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_6_ul_stat, { "NSAPI(6) uplink status", "gsm_a.gm.nsapi_6_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_7_ul_stat, { "NSAPI(7) uplink status", "gsm_a.gm.nsapi_7_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_8_ul_stat, { "NSAPI(8) uplink status", "gsm_a.gm.nsapi_8_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_9_ul_stat, { "NSAPI(9) uplink status", "gsm_a.gm.nsapi_9_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_10_ul_stat, { "NSAPI(10) uplink status", "gsm_a.gm.nsapi_10_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_11_ul_stat, { "NSAPI(11) uplink status", "gsm_a.gm.nsapi_11_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_12_ul_stat, { "NSAPI(12) uplink status", "gsm_a.gm.nsapi_12_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_13_ul_stat, { "NSAPI(13) uplink status", "gsm_a.gm.nsapi_13_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_14_ul_stat, { "NSAPI(14) uplink status", "gsm_a.gm.nsapi_14_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_nsapi_15_ul_stat, { "NSAPI(15) uplink status", "gsm_a.gm.nsapi_15_ul_stat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_nsapi_ul_stat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_pco_pid, @@ -6998,17 +7000,17 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_req_ms_info_irat, { "I-RAT","gsm_a.gm.req_ms_info_irat", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_req_ms_info_irat_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_req_ms_info_irat_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_req_ms_info_irat2, { "I-RAT2","gsm_a.gm.req_ms_info_irat2", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_req_ms_info_irat2_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_req_ms_info_irat2_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_ue_usage_setting, { "UE's usage setting","gsm_a.gm.ue_usage_setting", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_ue_usage_setting_vals), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_ue_usage_setting_vals), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_voice_domain_pref_for_eutran, @@ -7257,28 +7259,28 @@ proto_register_gsm_a_gm(void) NULL, HFILL } }, { &hf_gsm_a_gm_rac_ctrled_early_cm_sending, - { "Controlled early Classmark Sending", "gsm_a.gm.rac.comp_int_meas_cap", - FT_BOOLEAN, 8, TFS(&tfs_implemented_not_implemented), 0x0, + { "Controlled early Classmark Sending", "gsm_a.gm.rac.ctrled_early_cm_sending", + FT_BOOLEAN, BASE_NONE, TFS(&tfs_implemented_not_implemented), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_pseudo_sync, { "Pseudo Synchronisation", "gsm_a.gm.rac.pseudo_sync", - FT_BOOLEAN, 8, TFS(&tfs_present_not_present), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_present_not_present), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_vgcs, { "Voice Group Call Service", "gsm_a.gm.rac.vgcs", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_vgcs), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_vgcs), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_vbs, { "Voice Broadcast Service", "gsm_a.gm.rac.vbs", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_vbs), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_vbs), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_multislot_capability, { "Multislot capability struct", "gsm_a.gm.rac.multislot_capability", - FT_BOOLEAN, 8, TFS(&tfs_present_not_present), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_present_not_present), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_hscsd_multi_slot_class, @@ -7293,7 +7295,7 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_gprs_ext_dyn_alloc_cap, { "GPRS Extended Dynamic Allocation Capability", "gsm_a.gm.rac.gprs_ext_dyn_alloc_cap", - FT_BOOLEAN, 8, TFS(&tfs_implemented_not_implemented), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_implemented_not_implemented), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_ecsd_multi_slot_class, @@ -7308,7 +7310,7 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_egprs_ext_dyn_alloc_cap, { "EGPRS Extended Dynamic Allocation Capability", "gsm_a.gm.rac.egprs_ext_dyn_alloc_cap", - FT_BOOLEAN, 8, TFS(&tfs_implemented_not_implemented), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_implemented_not_implemented), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_dtm_gprs_multi_slot_class, @@ -7318,12 +7320,12 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_single_slt_dtm, { "Single Slot DTM", "gsm_a.gm.rac.single_slt_dtm", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_dtm_egprs_multi_slot_cls_pres, { "DTM EGPRS Multi Slot Class", "gsm_a.gm.rac.dtm_egprs_multi_slot_cls_pres", - FT_BOOLEAN, 8, TFS(&tfs_present_not_present), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_present_not_present), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_dtm_egprs_multi_slot_class, @@ -7333,62 +7335,62 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_8psk_pow_cap_pres, { "8PSK Power Capability Bits", "gsm_a.gm.rac.8psk_pow_cap_pres", - FT_BOOLEAN, 8, TFS(&tfs_present_not_present), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_present_not_present), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_comp_int_meas_cap, { "COMPACT Interference Measurement Capability", "gsm_a.gm.rac.comp_int_meas_cap", - FT_BOOLEAN, 8, TFS(&tfs_implemented_not_implemented), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_implemented_not_implemented), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rel_lev_ind, { "Revision Level Indicator", "gsm_a.gm.rel_lev_ind", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_revision_level_indicator), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_revision_level_indicator), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_umts_fdd_cap, { "UMTS FDD Radio Access Technology Capability", "gsm_a.gm.rac.umts_fdd_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_umts_384_tdd_ra_cap, { "UMTS 3.84 Mcps TDD Radio Access Technology Capability", "gsm_a.gm.rac.umts_384_tdd_ra_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_cdma2000_cap, { "CDMA 2000 Radio Access Technology Capability", "gsm_a.gm.rac.cdma2000_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_umts_128_tdd_ra_cap, { "UMTS 1.28 Mcps TDD Radio Access Technology Capability", "gsm_a.gm.rac.umts_128_tdd_ra_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_geran_feat_pkg, { "GERAN Feature Package 1", "gsm_a.gm.rac.geran_feat_pkg", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_mod_based_multi_slot_class_support, { "Modulation based multislot class support", "gsm_a.gm.rac.mod_based_multi_slot_class_support", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_geran_iu_mode_cap, { "GERAN Iu mode", "gsm_a.gm.rac.geran_iu_mode_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_flo_iu_cap, { "FLO Iu Capability", "gsm_a.gm.rac.flo_iu_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_mult_tbf_cap, { "Multiple TBF Capability", "gsm_a.gm.rac.mult_tbf_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_down_adv_rec_perf, @@ -7398,12 +7400,12 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_ext_rlc_mac_ctrl_msg_seg_cap, { "Extended RLC/MAC Control Message Segmentation Capability", "gsm_a.gm.rac.ext_rlc_mac_ctrl_msg_seg_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_dtm_enh_cap, { "DTM Enhancements Capability", "gsm_a.gm.rac.dtm_enh_cap", - FT_BOOLEAN, 8, TFS(&gsm_a_gm_dtm_enh_cap), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_gm_dtm_enh_cap), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_dtm_gprs_high_multi_slot_class, @@ -7418,12 +7420,12 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_ps_ho_cap, { "PS Handover Capability", "gsm_a.gm.rac.ps_ho_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_dtm_ho_cap, { "DTM Handover Capability", "gsm_a.gm.rac.dtm_ho_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_multi_slot_cap_red_down_dual_carrier, @@ -7433,27 +7435,27 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_down_dual_carrier_dtm_cap, { "Downlink Dual Carrier for DTM Capability", "gsm_a.gm.rac.down_dual_carrier_dtm_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_flex_ts_assign, { "Flexible Timeslot Assignment", "gsm_a.gm.rac.flex_ts_assign", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_gan_ps_ho_cap, { "GAN PS Handover Capability", "gsm_a.gm.rac.gan_ps_ho_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_rlc_non_pers_mode, { "RLC Non-persistent Mode", "gsm_a.gm.rac.rlc_non_pers_mode", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_reduced_lat_cap, { "Reduced Latency Capability", "gsm_a.gm.rac.reduced_lat_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_ul_egprs2, @@ -7468,12 +7470,12 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_eutra_fdd_support, { "E-UTRA FDD support", "gsm_a.gm.rac.eutra_fdd_support", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_eutra_tdd_support, { "E-UTRA TDD support", "gsm_a.gm.rac.eutra_tdd_support", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_geran_to_eutra_support_in_geran_ptm, @@ -7483,7 +7485,7 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_prio_based_resel_support, { "Priority-based reselection support", "gsm_a.gm.rac.prio_based_resel_support", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_alt_efta_multi_slot_class, @@ -7498,27 +7500,27 @@ proto_register_gsm_a_gm(void) }, { &hf_gsm_a_gm_rac_ind_up_layer_pdu_start_cap_for_rlc_um, { "Indication of Upper Layer PDU Start Capability for RLC UM", "gsm_a.gm.rac.ind_up_layer_pdu_start_cap_for_rlc_um", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_emst_cap, { "Enhanced Multiplexing for Single TBF Capability", "gsm_a.gm.rac.emst_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_mtti_cap, { "Multiple TTI Capability", "gsm_a.gm.rac.mtti_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_utra_csg_cell_report, { "UTRA CSG Cells Reporting", "gsm_a.gm.rac.utra_csg_cell_report", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_gm_rac_eutra_csg_cell_report, { "E-UTRA CSG Cells Reporting", "gsm_a.gm.rac.mtti_cap", - FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_supported_not_supported), 0x0, NULL, HFILL } }, { &hf_gsm_a_sm_ti_flag, @@ -7531,7 +7533,7 @@ proto_register_gsm_a_gm(void) FT_BOOLEAN, 8, NULL, 0x80, NULL, HFILL } }, -}; +}; /* Setup protocol subtree array */ #define NUM_INDIVIDUAL_ELEMS 18 diff --git a/epan/dissectors/packet-ieee80211.c b/epan/dissectors/packet-ieee80211.c index 7a875f8b62..ad41ba87dc 100644 --- a/epan/dissectors/packet-ieee80211.c +++ b/epan/dissectors/packet-ieee80211.c @@ -12367,7 +12367,7 @@ proto_register_ieee80211 (void) NULL, HFILL }}, {&hf_ieee80211_wep_iv_weak, - {"Weak IV", "wlan.wep.weakiv", FT_BOOLEAN,BASE_NONE, NULL,0x0, + {"Weak IV", "wlan.wep.weakiv", FT_BOOLEAN, BASE_NONE, NULL,0x0, NULL,HFILL}}, {&hf_ieee80211_tkip_extiv, @@ -13779,19 +13779,19 @@ proto_register_ieee80211 (void) FT_FRAMENUM, BASE_NONE, NULL, 0x00, NULL, HFILL } }, {&hf_ieee80211_gas_resp_fragment_overlap, {"GAS Query Response fragment overlap", "wlan_mgt.fixed.fragment.overlap", - FT_BOOLEAN, 0, NULL, 0x00, NULL, HFILL } }, + FT_BOOLEAN, BASE_NONE, NULL, 0x00, NULL, HFILL } }, {&hf_ieee80211_gas_resp_fragment_overlap_conflict, {"GAS Query Response fragment overlapping with conflicting data", "wlan_mgt.fixed.fragment.overlap.conflicts", - FT_BOOLEAN, 0, NULL, 0x00, NULL, HFILL } }, + FT_BOOLEAN, BASE_NONE, NULL, 0x00, NULL, HFILL } }, {&hf_ieee80211_gas_resp_fragment_multiple_tails, {"GAS Query Response has multiple tail fragments", "wlan_mgt.fixed.fragment.multiple_tails", - FT_BOOLEAN, 0, NULL, 0x00, NULL, HFILL } }, + FT_BOOLEAN, BASE_NONE, NULL, 0x00, NULL, HFILL } }, {&hf_ieee80211_gas_resp_fragment_too_long_fragment, {"GAS Query Response fragment too long", "wlan_mgt.fixed.fragment.too_long_fragment", - FT_BOOLEAN, 0, NULL, 0x00, NULL, HFILL } }, + FT_BOOLEAN, BASE_NONE, NULL, 0x00, NULL, HFILL } }, {&hf_ieee80211_gas_resp_fragment_error, {"GAS Query Response reassembly error", "wlan_mgt.fixed.fragment.error", FT_FRAMENUM, BASE_NONE, NULL, 0x00, NULL, HFILL } }, diff --git a/epan/dissectors/packet-ieee802154.c b/epan/dissectors/packet-ieee802154.c index 5f80b87f3e..53b64b90b5 100644 --- a/epan/dissectors/packet-ieee802154.c +++ b/epan/dissectors/packet-ieee802154.c @@ -31,7 +31,7 @@ *------------------------------------------------------------ * * In IEEE 802.15.4 packets, all fields are little endian. And - * Each byte is transmitted least significan bit first (reflected + * Each byte is transmitted least significant bit first (reflected * bit ordering). *------------------------------------------------------------ * @@ -107,7 +107,7 @@ static gboolean ieee802154_fcs_ok = TRUE; static const gchar *ieee802154_key_str = NULL; static gboolean ieee802154_key_valid; static guint8 ieee802154_key[IEEE802154_CIPHER_SIZE]; -static const char *ieee802154_user = "User"; +static const char *ieee802154_user = "User"; /*------------------------------------- * Address Hash Tables @@ -121,22 +121,22 @@ static ieee802154_map_tab_t ieee802154_map = { NULL, NULL }; */ /* UAT entry structure. */ typedef struct { - guchar * eui64; - guint eui64_len; - guint addr16; - guint pan; + guchar *eui64; + guint eui64_len; + guint addr16; + guint pan; } static_addr_t; /* UAT variables */ -static uat_t * static_addr_uat = NULL; -static static_addr_t * static_addrs = NULL; -static guint num_static_addrs = 0; +static uat_t *static_addr_uat = NULL; +static static_addr_t *static_addrs = NULL; +static guint num_static_addrs = 0; /* Sanity-checks a UAT record. */ static void -addr_uat_update_cb(void* r, const char** err) +addr_uat_update_cb(void *r, const char **err) { - static_addr_t * map = r; + static_addr_t *map = r; /* Ensure a valid short address */ if (map->addr16 >= IEEE802154_NO_ADDR16) { *err = "Invalid short address"; @@ -655,7 +655,7 @@ dissect_ieee802154_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, g col_add_fstr(pinfo->cinfo, COL_PACKET_LENGTH, "%i", tvb_length(tvb)); } - /* Add the packet length to the filter field */ + /* Add the packet length to the filter field */ hidden_item = proto_tree_add_uint(tree, hf_ieee802154_frame_length, NULL, 0, 0, tvb_reported_length(tvb)); PROTO_ITEM_SET_HIDDEN(hidden_item); @@ -2613,7 +2613,7 @@ void proto_register_ieee802154(void) "Whether the PAN coordinator is accepting GTS requests or not.", HFILL }}, { &hf_ieee802154_gts_direction, - { "Direction", "wpan.gts.direction", FT_BOOLEAN, 8, TFS(&ieee802154_gts_direction_tfs), 0x0, + { "Direction", "wpan.gts.direction", FT_BOOLEAN, BASE_NONE, TFS(&ieee802154_gts_direction_tfs), 0x0, "A flag defining the direction of the GTS Slot.", HFILL }}, { &hf_ieee802154_pending16, diff --git a/epan/dissectors/packet-kerberos.c b/epan/dissectors/packet-kerberos.c index 41a0e14574..3b8e9ef34e 100644 --- a/epan/dissectors/packet-kerberos.c +++ b/epan/dissectors/packet-kerberos.c @@ -5251,7 +5251,7 @@ proto_register_kerberos(void) "TransitedEncoding", "kerberos.TransitedEncoding", FT_NONE, BASE_NONE, NULL, 0, "This is a Kerberos TransitedEncoding sequence", HFILL }}, { &hf_krb_PA_PAC_REQUEST_flag, { - "PAC Request", "kerberos.pac_request.flag", FT_BOOLEAN, 32, + "PAC Request", "kerberos.pac_request.flag", FT_BOOLEAN, BASE_NONE, NULL, 0, "This is a MS PAC Request Flag", HFILL }}, { &hf_krb_w2k_pac_entries, { "Num Entries", "kerberos.pac.entries", FT_UINT32, BASE_DEC, diff --git a/epan/dissectors/packet-mac-lte.c b/epan/dissectors/packet-mac-lte.c index b24c689735..94d9d259af 100644 --- a/epan/dissectors/packet-mac-lte.c +++ b/epan/dissectors/packet-mac-lte.c @@ -1289,16 +1289,16 @@ static gint dissect_rar_entry(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tre proto_item *pdu_ti, gint offset, guint8 rapid) { - guint8 reserved; - guint start_body_offset = offset; + guint8 reserved; + guint start_body_offset = offset; proto_item *ti; proto_item *rar_body_ti; proto_tree *rar_body_tree; proto_tree *ul_grant_tree; proto_item *ul_grant_ti; - guint16 timing_advance; - guint32 ul_grant; - guint16 temp_crnti; + guint16 timing_advance; + guint32 ul_grant; + guint16 temp_crnti; /* Create tree for this Body */ rar_body_ti = proto_tree_add_item(tree, @@ -1379,17 +1379,17 @@ static gint dissect_rar_entry(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tre static void dissect_rar(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_item *pdu_ti, gint offset, mac_lte_info *p_mac_lte_info, mac_lte_tap_info *tap_info) { - gint number_of_rars = 0; /* No of RAR bodies expected following headers */ - guint8 *rapids = ep_alloc(MAX_RAR_PDUS * sizeof(guint8)); - gboolean backoff_indicator_seen = FALSE; - guint8 backoff_indicator = 0; - guint8 extension; - gint n; + gint number_of_rars = 0; /* No of RAR bodies expected following headers */ + guint8 *rapids = ep_alloc(MAX_RAR_PDUS * sizeof(guint8)); + gboolean backoff_indicator_seen = FALSE; + guint8 backoff_indicator = 0; + guint8 extension; + gint n; proto_tree *rar_headers_tree; proto_item *ti; proto_item *rar_headers_ti; proto_item *padding_length_ti; - int start_headers_offset = offset; + int start_headers_offset = offset; write_pdu_label_and_info(pdu_ti, NULL, pinfo, "RAR (RA-RNTI=%u, SF=%u) ", @@ -1670,7 +1670,7 @@ static void call_rlc_dissector(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tr guint8 UMSequenceNumberLength, guint8 priority) { - tvbuff_t *srb_tvb = tvb_new_subset(tvb, offset, data_length, data_length); + tvbuff_t *srb_tvb = tvb_new_subset(tvb, offset, data_length, data_length); struct rlc_lte_info *p_rlc_lte_info; /* Get RLC dissector handle */ @@ -2025,12 +2025,12 @@ static SRResult *GetSRResult(guint32 frameNum, gboolean can_create) static void TrackSRInfo(SREvent event, packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, mac_lte_info *p_mac_lte_info, gint idx, proto_item *event_ti) { - SRResult *result = NULL; - SRState *state; - SRResult *resultForSRFrame = NULL; + SRResult *result = NULL; + SRState *state; + SRResult *resultForSRFrame = NULL; - guint16 rnti; - guint16 ueid; + guint16 rnti; + guint16 ueid; proto_item *ti; /* Get appropriate identifiers */ @@ -2350,7 +2350,7 @@ static void lookup_rlc_channel_from_lcid(guint8 lcid, /* Zero params (in case no match is found) */ *rlc_channel_type = rlcRaw; *UM_seqnum_length = 0; - *drb_id = 0; + *drb_id = 0; if (global_mac_lte_lcid_drb_source == (int)FromStaticTable) { @@ -2417,16 +2417,16 @@ static void dissect_ulsch_or_dlsch(tvbuff_t *tvb, packet_info *pinfo, proto_tree proto_item *retx_ti, proto_tree *context_tree) { - guint8 extension; - volatile guint16 n; + guint8 extension; + volatile guint16 n; proto_item *truncated_ti; proto_item *padding_length_ti; proto_item *hidden_root_ti; /* Keep track of LCIDs and lengths as we dissect the header */ volatile guint16 number_of_headers = 0; - guint8 lcids[MAX_HEADERS_IN_PDU]; - gint16 pdu_lengths[MAX_HEADERS_IN_PDU]; + guint8 lcids[MAX_HEADERS_IN_PDU]; + gint16 pdu_lengths[MAX_HEADERS_IN_PDU]; proto_item *pdu_header_ti; proto_tree *pdu_header_tree; @@ -3285,8 +3285,8 @@ static void dissect_ulsch_or_dlsch(tvbuff_t *tvb, packet_info *pinfo, proto_tree static void dissect_mch(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_item *pdu_ti, volatile guint32 offset, mac_lte_info *p_mac_lte_info) { - guint8 extension; - volatile guint16 n; + guint8 extension; + volatile guint16 n; proto_item *truncated_ti; proto_item *padding_length_ti; proto_item *hidden_root_ti; @@ -3440,7 +3440,7 @@ static void dissect_mch(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, pro tvb, offset*8 + 1, 7, &length, ENC_BIG_ENDIAN); offset++; } - if ((lcids[number_of_headers] == MCH_SCHEDULING_INFO_LCID) && (length & 0x01)) { + if ((lcids[number_of_headers] == MCH_SCHEDULING_INFO_LCID) && (length & 0x01)) { expert_add_info_format(pinfo, lcid_ti, PI_MALFORMED, PI_WARN, "MCH Scheduling Information MAC Control Element should have an even size"); } @@ -3682,15 +3682,15 @@ static void dissect_mch(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, pro /* Main dissection function. */ void dissect_mac_lte(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) { - proto_tree *mac_lte_tree; - proto_item *pdu_ti; - proto_tree *context_tree; - proto_item *context_ti; - proto_item *retx_ti = NULL; - proto_item *ti; - gint offset = 0; - struct mac_lte_info *p_mac_lte_info = NULL; - gint n; + proto_tree *mac_lte_tree; + proto_item *pdu_ti; + proto_tree *context_tree; + proto_item *context_ti; + proto_item *retx_ti = NULL; + proto_item *ti; + gint offset = 0; + struct mac_lte_info *p_mac_lte_info = NULL; + gint n; /* Allocate and zero tap struct */ mac_lte_tap_info *tap_info = ep_alloc0(sizeof(mac_lte_tap_info)); @@ -4113,8 +4113,7 @@ void dissect_mac_lte(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) /* Initializes the hash tables each time a new * file is loaded or re-loaded in wireshark */ -static void -mac_lte_init_protocol(void) +static void mac_lte_init_protocol(void) { /* Destroy any existing tables. */ if (mac_lte_msg3_hash) { @@ -4172,7 +4171,7 @@ mac_lte_init_protocol(void) static void* lcid_drb_mapping_copy_cb(void* dest, const void* orig, size_t len _U_) { const lcid_drb_mapping_t *o = orig; - lcid_drb_mapping_t *d = dest; + lcid_drb_mapping_t *d = dest; /* Copy all items over */ d->lcid = o->lcid; @@ -4395,7 +4394,7 @@ void proto_register_mac_lte(void) }, { &hf_mac_lte_context_phy_dl_retx, { "DL Retx", - "mac-lte.dl-phy.dl-retx", FT_BOOLEAN, BASE_DEC, NULL, 0x0, + "mac-lte.dl-phy.dl-retx", FT_BOOLEAN, BASE_NONE, NULL, 0x0, NULL, HFILL } }, @@ -5193,8 +5192,7 @@ void set_mac_lte_proto_data(packet_info *pinfo, mac_lte_info *p_mac_lte_info) p_add_proto_data(pinfo->fd, proto_mac_lte, p_mac_lte_info); } -void -proto_reg_handoff_mac_lte(void) +void proto_reg_handoff_mac_lte(void) { static dissector_handle_t mac_lte_handle; if (!mac_lte_handle) { diff --git a/epan/dissectors/packet-opensafety.c b/epan/dissectors/packet-opensafety.c index b1e4d461da..fe6884b719 100644 --- a/epan/dissectors/packet-opensafety.c +++ b/epan/dissectors/packet-opensafety.c @@ -452,10 +452,10 @@ void proto_reg_handoff_opensafety(void); static guint16 findFrame1Position ( guint8 byteStream[], guint8 dataLength, gboolean checkIfSlimMistake ) { - guint16 i_wFrame1Position = 0; + guint16 i_wFrame1Position = 0; guint16 i_payloadLength, i_calculatedLength = 0; - guint16 i_offset = 0, calcCRC = 0, frameCRC = 0; - guint8 b_tempByte = 0; + guint16 i_offset = 0, calcCRC = 0, frameCRC = 0; + guint8 b_tempByte = 0; /* * First, a normal package get's assumed. Calculation of frame 1 position is @@ -514,11 +514,11 @@ findFrame1Position ( guint8 byteStream[], guint8 dataLength, gboolean checkIfSli /* * This function applies the given UDID to the bytestream, considering the start of frame 2 */ -static guint8 * unxorFrame(guint dataLength, guint8 byteStream[], guint16 frameStart1, guint16 frameStart2, guint8 scmUDID[]) +static guint8 *unxorFrame(guint dataLength, guint8 byteStream[], guint16 frameStart1, guint16 frameStart2, guint8 scmUDID[]) { guint8 * pb_sendMemBlock; - guint k; - guint8 frame1Size; + guint k; + guint8 frame1Size; frame1Size = ( frameStart2 > frameStart1 ? frameStart2 : dataLength - frameStart1 ); frame1Size = MIN(frame1Size, dataLength); @@ -533,11 +533,11 @@ static guint8 * unxorFrame(guint dataLength, guint8 byteStream[], guint16 frameS return pb_sendMemBlock; } -static guint8 findSafetyFrame ( guint8 * pBuffer, guint32 length, guint u_Offset, gboolean b_frame2first, guint *u_frameOffset, guint *u_frameLength ) +static guint8 findSafetyFrame ( guint8 *pBuffer, guint32 length, guint u_Offset, gboolean b_frame2first, guint *u_frameOffset, guint *u_frameLength ) { - guint n; - guint16 crc, calcCrc; - guint8 b_ID, b_Length, crcOffset, leftShifted; + guint n; + guint16 crc, calcCrc; + guint8 b_ID, b_Length, crcOffset, leftShifted; gboolean found; found = 0; @@ -622,14 +622,14 @@ static guint8 findSafetyFrame ( guint8 * pBuffer, guint32 length, guint u_Offset static void dissect_opensafety_spdo_message(tvbuff_t *message_tvb, packet_info *pinfo, proto_tree *opensafety_tree, - guint8 * bytes, guint16 frameStart1, guint16 frameStart2 , gboolean validSCMUDID) + guint8 *bytes, guint16 frameStart1, guint16 frameStart2 , gboolean validSCMUDID) { proto_item *item; proto_tree *spdo_tree; - guint16 ct; - gint16 taddr; - guint dataLength; - guint8 tr, b_ID, conn_Valid; + guint16 ct; + gint16 taddr; + guint dataLength; + guint8 tr, b_ID, conn_Valid; dataLength = tvb_get_guint8(message_tvb, OSS_FRAME_POS_LEN + frameStart1); b_ID = ( bytes[frameStart1 + 1] >> 3 ) << 3; @@ -711,17 +711,17 @@ dissect_opensafety_spdo_message(tvbuff_t *message_tvb, packet_info *pinfo, proto static void -dissect_opensafety_ssdo_message(tvbuff_t *message_tvb , packet_info * pinfo, proto_tree *opensafety_tree , - guint8 * bytes, guint16 frameStart1, guint16 frameStart2 , gboolean validSCMUDID) +dissect_opensafety_ssdo_message(tvbuff_t *message_tvb , packet_info *pinfo, proto_tree *opensafety_tree , + guint8 *bytes, guint16 frameStart1, guint16 frameStart2 , gboolean validSCMUDID) { proto_item *item; proto_tree *ssdo_tree, *ssdo_sacmd_tree; - guint16 taddr = 0 ; - guint32 abortcode; - guint8 db0Offset, db0, sacmd, payloadOffset, payloadSize, n; - guint dataLength; - gboolean isRequest; - guint8 * payload; + guint16 taddr = 0 ; + guint32 abortcode; + guint8 db0Offset, db0, sacmd, payloadOffset, payloadSize, n; + guint dataLength; + gboolean isRequest; + guint8 *payload; dataLength = tvb_get_guint8(message_tvb, OSS_FRAME_POS_LEN + frameStart1); @@ -885,13 +885,13 @@ dissect_opensafety_ssdo_message(tvbuff_t *message_tvb , packet_info * pinfo, pro static void dissect_opensafety_snmt_message(tvbuff_t *message_tvb, packet_info *pinfo , proto_tree *opensafety_tree, - guint8 * bytes, guint16 frameStart1, guint16 frameStart2 ) + guint8 *bytes, guint16 frameStart1, guint16 frameStart2 ) { proto_item *item; proto_tree *snmt_tree; - guint16 addr, taddr; - guint8 db0, byte; - guint dataLength; + guint16 addr, taddr; + guint8 db0, byte; + guint dataLength; dataLength = OSS_FRAME_LENGTH(bytes, frameStart1); @@ -1030,15 +1030,15 @@ dissect_opensafety_snmt_message(tvbuff_t *message_tvb, packet_info *pinfo , prot } static gboolean -dissect_opensafety_checksum(tvbuff_t *message_tvb, proto_tree *opensafety_tree, guint8 * bytes, guint16 frameStart1 ) +dissect_opensafety_checksum(tvbuff_t *message_tvb, proto_tree *opensafety_tree, guint8 *bytes, guint16 frameStart1 ) { - guint16 frameCrc; - guint16 calcCrc; - guint dataLength; - proto_item * item; + guint16 frameCrc; + guint16 calcCrc; + guint dataLength; + proto_item *item; proto_tree *checksum_tree; - gint start; - gint length; + gint start; + gint length; dataLength = OSS_FRAME_LENGTH(bytes, frameStart1); start = OSS_FRAME_POS_DATA + dataLength + frameStart1; @@ -1071,13 +1071,13 @@ dissect_opensafety_message(guint16 frameStart1, guint16 frameStart2, guint8 type tvbuff_t *message_tvb, packet_info *pinfo, proto_item *opensafety_item, proto_tree *opensafety_tree, guint8 u_nrInPackage) { - guint8 b_ID; - guint length; - guint8 * bytes; + guint8 b_ID; + guint length; + guint8 *bytes; GByteArray *scmUDID = NULL; - gboolean validSCMUDID; - proto_item * item; - gboolean messageTypeUnknown, crcValid; + gboolean validSCMUDID; + proto_item *item; + gboolean messageTypeUnknown, crcValid; messageTypeUnknown = FALSE; length = tvb_length(message_tvb); @@ -1125,7 +1125,8 @@ dissect_opensafety_message(guint16 frameStart1, guint16 frameStart2, guint8 type item = proto_tree_add_boolean(opensafety_tree, hf_oss_scm_udid_valid, message_tvb, 0, 0, validSCMUDID); if ( scmUDID->len != 6 ) - expert_add_info_format(pinfo, item, PI_MALFORMED, PI_WARN, "openSAFETY protocol settings are invalid! SCM UDID first octet will be assumed to be 00" ); + expert_add_info_format(pinfo, item, PI_MALFORMED, PI_WARN, + "openSAFETY protocol settings are invalid! SCM UDID first octet will be assumed to be 00" ); PROTO_ITEM_SET_GENERATED(item); g_byte_array_free( scmUDID, TRUE); @@ -1145,7 +1146,8 @@ dissect_opensafety_message(guint16 frameStart1, guint16 frameStart2, guint8 type } crcValid = FALSE; - item = proto_tree_add_uint(opensafety_tree, hf_oss_length, message_tvb, OSS_FRAME_POS_LEN + frameStart1, 1, OSS_FRAME_LENGTH(bytes, frameStart1)); + item = proto_tree_add_uint(opensafety_tree, hf_oss_length, + message_tvb, OSS_FRAME_POS_LEN + frameStart1, 1, OSS_FRAME_LENGTH(bytes, frameStart1)); if ( messageTypeUnknown ) { expert_add_info_format(pinfo, item, PI_MALFORMED, PI_ERROR, "Unknown openSAFETY message type" ); @@ -1178,25 +1180,25 @@ dissect_opensafety_message(guint16 frameStart1, guint16 frameStart2, guint8 type } static gboolean -opensafety_package_dissector(const gchar * protocolName, const gchar * sub_diss_handle, +opensafety_package_dissector(const gchar *protocolName, const gchar *sub_diss_handle, gboolean b_frame2First, gboolean do_byte_swap, guint8 force_nr_in_package, tvbuff_t *message_tvb , packet_info *pinfo , proto_tree *tree ) { - tvbuff_t *next_tvb; - guint length, len, frameOffset, frameLength, nodeAddress; - guint8 *bytes, *bytesOffset; - gboolean handled, dissectorCalled, call_sub_dissector, markAsMalformed; - guint8 type, found, packageCounter, i, tempByte; - guint16 frameStart1, frameStart2; - gint reported_len; - dissector_handle_t protocol_dissector = NULL; - proto_item *opensafety_item; - proto_tree *opensafety_tree; - - handled = FALSE; - dissectorCalled = FALSE; + tvbuff_t *next_tvb; + guint length, len, frameOffset, frameLength, nodeAddress; + guint8 *bytes, *bytesOffset; + gboolean handled, dissectorCalled, call_sub_dissector, markAsMalformed; + guint8 type, found, packageCounter, i, tempByte; + guint16 frameStart1, frameStart2; + gint reported_len; + dissector_handle_t protocol_dissector = NULL; + proto_item *opensafety_item; + proto_tree *opensafety_tree; + + handled = FALSE; + dissectorCalled = FALSE; call_sub_dissector = FALSE; - markAsMalformed = FALSE; + markAsMalformed = FALSE; length = tvb_length(message_tvb); /* Minimum package length is 11 */ @@ -1406,8 +1408,8 @@ static gboolean dissect_opensafety_epl(tvbuff_t *message_tvb , packet_info *pinfo , proto_tree *tree ) { static gboolean calledOnce = FALSE; - gboolean result = FALSE; - guint8 firstByte; + gboolean result = FALSE; + guint8 firstByte; /* We will call the epl dissector by using call_dissector(). The epl dissector will then call * the heuristic openSAFETY dissector again. By setting this information, we prevent a dissector @@ -1436,8 +1438,8 @@ static gboolean dissect_opensafety_siii(tvbuff_t *message_tvb , packet_info *pinfo , proto_tree *tree ) { static gboolean calledOnce = FALSE; - gboolean result = FALSE; - guint8 firstByte; + gboolean result = FALSE; + guint8 firstByte; if ( pinfo->ipproto == IPPROTO_UDP ) { @@ -1470,7 +1472,7 @@ static gboolean dissect_opensafety_pn_io(tvbuff_t *message_tvb , packet_info *pinfo , proto_tree *tree ) { static gboolean calledOnce = FALSE; - gboolean result = FALSE; + gboolean result = FALSE; /* We will call the epl dissector by using call_dissector(). The epl dissector will then call * the heuristic openSAFETY dissector again. By setting this information, we prevent a dissector @@ -1499,7 +1501,7 @@ dissect_opensafety_mbtcp(tvbuff_t *message_tvb , packet_info *pinfo , proto_tree static gboolean dissect_opensafety_udpdata(tvbuff_t *message_tvb , packet_info *pinfo , proto_tree *tree ) { - gboolean result = FALSE; + gboolean result = FALSE; static guint32 frameNum = 0; static guint32 frameIdx = 0; @@ -1528,8 +1530,8 @@ static void apply_prefs ( void ) { static gboolean opensafety_init = FALSE; - static guint opensafety_udp_port_number; - static guint opensafety_udp_siii_port_number; + static guint opensafety_udp_port_number; + static guint opensafety_udp_siii_port_number; /* It only should delete dissectors, if run for any time except the first */ if ( opensafety_init ) @@ -1699,7 +1701,7 @@ proto_register_opensafety(void) /* SPDO Specific fields */ { &hf_oss_spdo_connection_valid, { "Connection Valid Bit", "opensafety.spdo.connection_valid", - FT_BOOLEAN, 8, TFS(&opensafety_set_notset), 0x0, NULL, HFILL } }, + FT_BOOLEAN, BASE_NONE, TFS(&opensafety_set_notset), 0x0, NULL, HFILL } }, { &hf_oss_spdo_payload, { "SPDO Payload", "opensafety.spdo.payload", FT_BYTES, BASE_NONE, NULL, 0x0, NULL, HFILL } }, diff --git a/epan/dissectors/packet-rtmpt.c b/epan/dissectors/packet-rtmpt.c index 16fa656b9a..4171306b3f 100644 --- a/epan/dissectors/packet-rtmpt.c +++ b/epan/dissectors/packet-rtmpt.c @@ -405,11 +405,11 @@ typedef struct rtmpt_frag { * ID - used for defaulting short headers */ typedef struct rtmpt_id { - guint32 ts; /* bytes 1-3 */ + guint32 ts; /* bytes 1-3 */ guint32 tsd; - guint32 len; /* bytes 4-6 */ - guint32 src; /* bytes 8-11 */ - guint8 cmd; /* byte 7 */ + guint32 len; /* bytes 4-6 */ + guint32 src; /* bytes 8-11 */ + guint8 cmd; /* byte 7 */ emem_tree_t *packets; } rtmpt_id_t; @@ -916,7 +916,7 @@ dissect_rtmpt_body_command(tvbuff_t *tvb, gint offset, proto_tree *rtmpt_tree, g iPropertyOffset, iPropertyLength+iValueExtra+iValueLength, "Property '%s' %s%s", - sProperty, val_to_str(iObjType, rtmpt_type_vals, "Unknown"), sValue); + sProperty, val_to_str_const(iObjType, rtmpt_type_vals, "Unknown"), sValue); rtmpt_tree_prop = proto_item_add_subtree(ti, ett_rtmpt_property); ti = proto_tree_add_text(rtmpt_tree_prop, tvb, @@ -934,7 +934,7 @@ dissect_rtmpt_body_command(tvbuff_t *tvb, gint offset, proto_tree *rtmpt_tree, g ti = proto_tree_add_text(rtmpt_tree_prop, tvb, iValueOffset-iValueExtra, iValueExtra+iValueLength, "%s%s", - val_to_str(iObjType, rtmpt_type_vals, "Unknown"), sValue); + val_to_str_const(iObjType, rtmpt_type_vals, "Unknown"), sValue); val_tree = proto_item_add_subtree(ti, ett_rtmpt_value); proto_tree_add_item(val_tree, hf_rtmpt_amf_type, tvb, iValueOffset-iValueExtra, 1, ENC_BIG_ENDIAN); @@ -943,7 +943,7 @@ dissect_rtmpt_body_command(tvbuff_t *tvb, gint offset, proto_tree *rtmpt_tree, g } else if (iObjType==RTMPT_AMF_LONG_STRING || iObjType==RTMPT_AMF_XML) { proto_tree_add_item(val_tree, hf_rtmpt_amf_longstringlength, tvb, iValueOffset-iValueExtra+1, 4, ENC_BIG_ENDIAN); } - if (iValueLength>0 && hfvalue!=-1) { + if (iValueLength>0 && hfvalue != -1) { proto_tree_add_item(val_tree, hfvalue, tvb, iValueOffset, iValueLength, FALSE); } } @@ -1006,10 +1006,10 @@ dissect_rtmpt_body_audio(tvbuff_t *tvb, gint offset, proto_tree *rtmpt_tree) iCtl = tvb_get_guint8(tvb, offset); ai = proto_tree_add_uint_format(rtmpt_tree, hf_rtmpt_audio_control, tvb, offset, 1, iCtl, "Control: 0x%02x (%s %s %s %s)", iCtl, - val_to_str((iCtl & 0xf0)>>4, rtmpt_audio_codecs, "Unknown codec"), - val_to_str((iCtl & 0x0c)>>2, rtmpt_audio_rates, "Unknown rate"), - val_to_str((iCtl & 0x02)>>1, rtmpt_audio_sizes, "Unknown sample size"), - val_to_str(iCtl & 0x01, rtmpt_audio_types, "Unknown channel count")); + val_to_str_const((iCtl & 0xf0)>>4, rtmpt_audio_codecs, "Unknown codec"), + val_to_str_const((iCtl & 0x0c)>>2, rtmpt_audio_rates, "Unknown rate"), + val_to_str_const((iCtl & 0x02)>>1, rtmpt_audio_sizes, "Unknown sample size"), + val_to_str_const(iCtl & 0x01, rtmpt_audio_types, "Unknown channel count")); at = proto_item_add_subtree(ai, ett_rtmpt_audio_control); proto_tree_add_uint(at, hf_rtmpt_audio_format, tvb, offset, 1, iCtl); @@ -1029,8 +1029,8 @@ dissect_rtmpt_body_video(tvbuff_t *tvb, gint offset, proto_tree *rtmpt_tree) iCtl = tvb_get_guint8(tvb, offset); vi = proto_tree_add_uint_format(rtmpt_tree, hf_rtmpt_video_control, tvb, offset, 1, iCtl, "Control: 0x%02x (%s %s)", iCtl, - val_to_str((iCtl & 0xf0)>>4, rtmpt_video_types, "Unknown frame type"), - val_to_str(iCtl & 0x0f, rtmpt_video_codecs, "Unknown codec")); + val_to_str_const((iCtl & 0xf0)>>4, rtmpt_video_types, "Unknown frame type"), + val_to_str_const(iCtl & 0x0f, rtmpt_video_codecs, "Unknown codec")); vt = proto_item_add_subtree(vi, ett_rtmpt_video_control); proto_tree_add_uint(vt, hf_rtmpt_video_type, tvb, offset, 1, iCtl); @@ -1054,7 +1054,8 @@ dissect_rtmpt_body_aggregate(tvbuff_t *tvb, gint offset, proto_tree *rtmpt_tree) iTagType = tvb_get_guint8(tvb, offset + 0); iDataSize = tvb_get_ntoh24(tvb, offset + 1); - tag_item = proto_tree_add_text(rtmpt_tree, tvb, offset, 11+iDataSize+4, "%s", val_to_str(iTagType, rtmpt_tag_vals, "Unknown Tag")); + tag_item = proto_tree_add_text(rtmpt_tree, tvb, offset, 11+iDataSize+4, "%s", + val_to_str_const(iTagType, rtmpt_tag_vals, "Unknown Tag")); tag_tree = proto_item_add_subtree(tag_item, ett_rtmpt_tag); proto_tree_add_item(tag_tree, hf_rtmpt_tag_type, tvb, offset+0, 1, ENC_BIG_ENDIAN); proto_tree_add_item(tag_tree, hf_rtmpt_tag_datasize, tvb, offset+1, 3, ENC_BIG_ENDIAN); @@ -1089,17 +1090,17 @@ dissect_rtmpt_body_aggregate(tvbuff_t *tvb, gint offset, proto_tree *rtmpt_tree) static void dissect_rtmpt(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, rtmpt_conv_t *rconv, int cdir, rtmpt_packet_t *tp) { - proto_tree *rtmpt_tree = NULL; - proto_tree *rtmptroot_tree = NULL; - proto_item *ti = NULL; - static guint iPreviousFrameNumber = 0; - gint offset = 0; - - gchar *sDesc = NULL; - gint deschasopcode = FALSE; - gboolean haveETS = FALSE; - guint32 iBodyOffset = 0; - guint32 iBodyRemain = 0; + proto_tree *rtmpt_tree = NULL; + proto_tree *rtmptroot_tree = NULL; + proto_item *ti = NULL; + static guint iPreviousFrameNumber = 0; + gint offset = 0; + + gchar *sDesc = NULL; + gint deschasopcode = FALSE; + gboolean haveETS = FALSE; + guint32 iBodyOffset = 0; + guint32 iBodyRemain = 0; col_set_str(pinfo->cinfo, COL_PROTOCOL, "RTMP"); @@ -1953,7 +1954,7 @@ proto_register_rtmpt(void) NULL, 0x0, "RTMPT AMF number", HFILL }}, { &hf_rtmpt_amf_boolean, - { "Boolean", "rtmpt.amf.boolean", FT_BOOLEAN, BASE_DEC, + { "Boolean", "rtmpt.amf.boolean", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "RTMPT AMF boolean", HFILL }}, { &hf_rtmpt_amf_stringlength, diff --git a/epan/dissectors/packet-vnc.c b/epan/dissectors/packet-vnc.c index ad5c93c5c9..469465a352 100644 --- a/epan/dissectors/packet-vnc.c +++ b/epan/dissectors/packet-vnc.c @@ -88,8 +88,8 @@ static const value_string vnc_security_types_vs[] = { }; static const true_false_string auth_result_tfs = { - "Failed", - "OK" + "Failed", + "OK" }; static const value_string yes_no_vs[] = { @@ -621,13 +621,13 @@ static void dissect_vnc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) { gboolean ret; - gint offset = 0; + gint offset = 0; /* Set up structures needed to add the protocol subtree and manage it */ - proto_item *ti=NULL; - proto_tree *vnc_tree=NULL; + proto_item *ti = NULL; + proto_tree *vnc_tree = NULL; - conversation_t *conversation; + conversation_t *conversation; vnc_conversation_t *per_conversation_info; conversation = find_or_create_conversation(pinfo); @@ -1257,7 +1257,7 @@ vnc_client_to_server(tvbuff_t *tvb, packet_info *pinfo, gint *offset, { guint8 message_type; - proto_item *ti=NULL; + proto_item *ti = NULL; proto_tree *vnc_client_message_type_tree; message_type = tvb_get_guint8(tvb, *offset); @@ -1318,7 +1318,7 @@ vnc_server_to_client(tvbuff_t *tvb, packet_info *pinfo, gint *offset, guint8 message_type; gint bytes_needed = 0, length_remaining; - proto_item *ti=NULL; + proto_item *ti = NULL; proto_tree *vnc_server_message_type_tree; start_offset = *offset; @@ -1434,8 +1434,8 @@ static void vnc_client_set_encodings(tvbuff_t *tvb, packet_info *pinfo, gint *offset, proto_tree *tree) { - guint16 number_of_encodings; - guint counter; + guint16 number_of_encodings; + guint counter; vnc_packet_t *per_packet_info; per_packet_info = p_get_proto_data(pinfo->fd, proto_vnc); @@ -1586,10 +1586,10 @@ static guint vnc_server_framebuffer_update(tvbuff_t *tvb, packet_info *pinfo, gint *offset, proto_tree *tree) { - gint i; - guint16 num_rects, width, height; - guint bytes_needed = 0; - guint32 encoding_type; + gint i; + guint16 num_rects, width, height; + guint bytes_needed = 0; + guint32 encoding_type; proto_item *ti, *ti_x, *ti_y, *ti_width, *ti_height; proto_tree *vnc_rect_tree, *vnc_encoding_type_tree; @@ -1745,7 +1745,7 @@ static guint32 vnc_extended_desktop_size(tvbuff_t *tvb, gint *offset, proto_tree *tree) { - guint8 i, num_of_screens; + guint8 i, num_of_screens; proto_item *ti; proto_tree *screen_tree; @@ -1814,9 +1814,9 @@ static guint vnc_rre_encoding(tvbuff_t *tvb, packet_info *pinfo, gint *offset, proto_tree *tree, const guint16 width _U_, const guint16 height _U_) { - guint8 bytes_per_pixel = vnc_get_bytes_per_pixel(pinfo); - guint32 num_subrects, i; - guint bytes_needed; + guint8 bytes_per_pixel = vnc_get_bytes_per_pixel(pinfo); + guint32 num_subrects, i; + guint bytes_needed; proto_item *ti; proto_tree *subrect_tree; @@ -1879,12 +1879,12 @@ static guint vnc_hextile_encoding(tvbuff_t *tvb, packet_info *pinfo, gint *offset, proto_tree *tree, const guint16 width, const guint16 height) { - guint8 bytes_per_pixel = vnc_get_bytes_per_pixel(pinfo); - guint8 i, subencoding_mask, num_subrects, subrect_len, tile_height, tile_width; - guint32 raw_length; + guint8 bytes_per_pixel = vnc_get_bytes_per_pixel(pinfo); + guint8 i, subencoding_mask, num_subrects, subrect_len, tile_height, tile_width; + guint32 raw_length; proto_tree *tile_tree, *subencoding_mask_tree, *subrect_tree, *num_subrects_tree; proto_item *ti, *tile_item; - guint16 current_height = 0, current_width; + guint16 current_height = 0, current_width; while(current_height != height) { if (current_height + 16 > height) @@ -2353,10 +2353,10 @@ vnc_rich_cursor_encoding(tvbuff_t *tvb, packet_info *pinfo, gint *offset, proto_tree *tree, const guint16 width, const guint16 height) { guint8 bytes_per_pixel = vnc_get_bytes_per_pixel(pinfo); - guint pixels_bytes, mask_bytes; + guint pixels_bytes, mask_bytes; pixels_bytes = width * height * bytes_per_pixel; - mask_bytes = ((width + 7) / 8) * height; + mask_bytes = ((width + 7) / 8) * height; return decode_cursor(tvb, offset, tree, pixels_bytes, mask_bytes); @@ -2368,7 +2368,7 @@ vnc_x_cursor_encoding(tvbuff_t *tvb, packet_info *pinfo _U_, gint *offset, proto_tree *tree, const guint16 width, const guint16 height) { gint bitmap_row_bytes = (width + 7) / 8; - gint mask_bytes = bitmap_row_bytes * height; + gint mask_bytes = bitmap_row_bytes * height; VNC_BYTES_NEEDED (6); proto_tree_add_item(tree, hf_vnc_cursor_x_fore_back, tvb, *offset, 6, ENC_NA); @@ -2465,7 +2465,7 @@ static guint vnc_server_cut_text(tvbuff_t *tvb, packet_info *pinfo, gint *offset, proto_tree *tree) { - guint32 text_len; + guint32 text_len; proto_item *pi; col_set_str(pinfo->cinfo, COL_INFO, "Server cut text"); @@ -2908,7 +2908,7 @@ proto_register_vnc(void) /* Client Key Event */ { &hf_vnc_key_down, { "Key down", "vnc.key_down", - FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x0, + FT_BOOLEAN, BASE_NONE, TFS(&tfs_yes_no), 0x0, "Specifies whether the key is being pressed or not", HFILL } }, { &hf_vnc_key, -- cgit v1.2.3