diff options
author | Jaap Keuter <jaap.keuter@xs4all.nl> | 2011-01-19 22:53:46 +0000 |
---|---|---|
committer | Jaap Keuter <jaap.keuter@xs4all.nl> | 2011-01-19 22:53:46 +0000 |
commit | c5c0a0d943fe8c0551fb07cdd2b6e99c0c4d0c0a (patch) | |
tree | 2f3af28fbfe7540fc914750baf6e6af88df9ed0c /plugins/wimax | |
parent | c732e15d7791aaa4006d3dbc7794e86adf94db3c (diff) | |
download | wireshark-c5c0a0d943fe8c0551fb07cdd2b6e99c0c4d0c0a.tar.gz |
Use Wireshark standard marking for unused parameters.
svn path=/trunk/; revision=35590
Diffstat (limited to 'plugins/wimax')
-rw-r--r-- | plugins/wimax/msg_dlmap.c | 11 | ||||
-rw-r--r-- | plugins/wimax/msg_pmc.c | 8 | ||||
-rw-r--r-- | plugins/wimax/msg_ulmap.c | 8 | ||||
-rw-r--r-- | plugins/wimax/packet-wmx.c | 9 | ||||
-rw-r--r-- | plugins/wimax/wimax_bits.h | 6 | ||||
-rw-r--r-- | plugins/wimax/wimax_compact_dlmap_ie_decoder.c | 24 | ||||
-rw-r--r-- | plugins/wimax/wimax_tlv.h | 4 |
7 files changed, 15 insertions, 55 deletions
diff --git a/plugins/wimax/msg_dlmap.c b/plugins/wimax/msg_dlmap.c index d8ee6b1ff8..c19bc362b3 100644 --- a/plugins/wimax/msg_dlmap.c +++ b/plugins/wimax/msg_dlmap.c @@ -2029,7 +2029,7 @@ gint dissect_dlmap_ie(proto_tree *ie_tree, const guint8 *bufptr, gint offset, gi } -void dissect_mac_mgmt_msg_dlmap_decoder(tvbuff_t *tvb, packet_info *pinfo, proto_tree *base_tree) +void dissect_mac_mgmt_msg_dlmap_decoder(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *base_tree) { /* 6.3.2.3.2 [2] DL-MAP table 16 */ guint offset = 0; @@ -2042,8 +2042,6 @@ void dissect_mac_mgmt_msg_dlmap_decoder(tvbuff_t *tvb, packet_info *pinfo, proto /* XXX This should be removed, and regular tvb accessors should be used instead. */ const guint8 *bufptr = tvb_get_ptr(tvb, offset, tvb_len); - UNREFERENCED_PARAMETER(pinfo); - INC_CID = 0; /* add protocol */ @@ -2186,7 +2184,7 @@ extern gint dissect_ulmap_ie(proto_tree *ie_tree, extern gint wimax_decode_ulmap_reduced_aas(proto_tree *ie_tree, const guint8 *bufptr, gint offset, gint length, tvbuff_t *tvb); -gint wimax_decode_sub_dl_ul_map(tvbuff_t *tvb, packet_info *pinfo, proto_tree *base_tree) +gint wimax_decode_sub_dl_ul_map(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *base_tree) { /* decode a SUB-DL-UL-MAP message 6.3.2.3.60 and return the length in bytes */ /* first three bits are 0x7, which following a compressed DL map indicates this message */ @@ -2205,8 +2203,6 @@ gint wimax_decode_sub_dl_ul_map(tvbuff_t *tvb, packet_info *pinfo, proto_tree *b gint nib = 0; gint lennib = BYTE_TO_NIB(length); - UNREFERENCED_PARAMETER(pinfo); - sub_dl_ul_map = 1; /* set flag */ ti = proto_tree_add_text(base_tree, tvb, NIBHI(nib,lennib-nib), "SUB-DL-UL-MAP"); @@ -2278,7 +2274,7 @@ gint wimax_decode_sub_dl_ul_map(tvbuff_t *tvb, packet_info *pinfo, proto_tree *b return length; } -gint wimax_decode_dlmap_reduced_aas(tvbuff_t *tvb, packet_info *pinfo, proto_tree *base_tree) +gint wimax_decode_dlmap_reduced_aas(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *base_tree) { /* 8.4.5.8.1 [2] Reduced AAS private DL-MAP */ /* if there is an appended UL-MAP, also decode that */ @@ -2298,7 +2294,6 @@ gint wimax_decode_dlmap_reduced_aas(tvbuff_t *tvb, packet_info *pinfo, proto_tre guint16 calculated_crc; gint smcs,cidi,dcdi,phyi,cqci; - UNREFERENCED_PARAMETER(pinfo); length = tvb_len; /* display MAC Reduced_AAS_Private_DL-MAP and create subtree */ diff --git a/plugins/wimax/msg_pmc.c b/plugins/wimax/msg_pmc.c index 570031badd..a774d41747 100644 --- a/plugins/wimax/msg_pmc.c +++ b/plugins/wimax/msg_pmc.c @@ -189,15 +189,13 @@ void proto_register_mac_mgmt_msg_pmc_rsp(void) } /* Decode PMC-REQ messages. */ -void dissect_mac_mgmt_msg_pmc_req_decoder(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) +void dissect_mac_mgmt_msg_pmc_req_decoder(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree) { guint offset = 0; guint tvb_len, payload_type; proto_item *pmc_req_item = NULL; proto_tree *pmc_req_tree = NULL; - UNREFERENCED_PARAMETER(pinfo); - /* Ensure the right payload type */ payload_type = tvb_get_guint8(tvb, 0); if(payload_type != MAC_MGMT_MSG_PMC_REQ) @@ -229,7 +227,7 @@ void dissect_mac_mgmt_msg_pmc_req_decoder(tvbuff_t *tvb, packet_info *pinfo, pro } /* Decode PMC-RSP messages. */ -void dissect_mac_mgmt_msg_pmc_rsp_decoder(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) +void dissect_mac_mgmt_msg_pmc_rsp_decoder(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree) { guint offset = 0; guint tvb_len, payload_type; @@ -239,8 +237,6 @@ void dissect_mac_mgmt_msg_pmc_rsp_decoder(tvbuff_t *tvb, packet_info *pinfo, pro gint8 value; gfloat power_change; - UNREFERENCED_PARAMETER(pinfo); - /* Ensure the right payload type */ payload_type = tvb_get_guint8(tvb, 0); if(payload_type != MAC_MGMT_MSG_PMC_RSP) diff --git a/plugins/wimax/msg_ulmap.c b/plugins/wimax/msg_ulmap.c index 89f0b9ba38..cb5113967d 100644 --- a/plugins/wimax/msg_ulmap.c +++ b/plugins/wimax/msg_ulmap.c @@ -1601,7 +1601,7 @@ void lshift_bits(guint8 *buffer, gint bytes, gint bits) -gint dissect_ulmap_ie( proto_tree *ie_tree, const guint8 *bufptr, gint offset, gint length, tvbuff_t *tvb) +gint dissect_ulmap_ie( proto_tree *ie_tree, const guint8 *bufptr, gint offset, gint length _U_, tvbuff_t *tvb) { /* decode a single UL-MAP IE and return the * length of the IE in nibbles @@ -1617,8 +1617,6 @@ gint dissect_ulmap_ie( proto_tree *ie_tree, const guint8 *bufptr, gint offset, g nibble = offset; - UNREFERENCED_PARAMETER(length); - /* 8.4.5.4 UL-MAP IE format - table 287 */ cid = NIB_WORD(nibble, bufptr); uiuc = NIB_NIBBLE(nibble + 4, bufptr); @@ -1898,7 +1896,7 @@ gint dissect_ulmap_ie( proto_tree *ie_tree, const guint8 *bufptr, gint offset, g return (nibble - offset); } -void dissect_mac_mgmt_msg_ulmap_decoder(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) +void dissect_mac_mgmt_msg_ulmap_decoder(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree) { /* 6.3.2.3.4 [2] UL-MAP table 18 */ guint offset = 0; @@ -1914,8 +1912,6 @@ void dissect_mac_mgmt_msg_ulmap_decoder(tvbuff_t *tvb, packet_info *pinfo, proto /* XXX This should be removed, and regular tvb accessors should be used instead. */ bufptr = tvb_get_ptr(tvb, offset, tvb_len); - UNREFERENCED_PARAMETER(pinfo); - /* display MAC UL-MAP */ ti = proto_tree_add_protocol_format(tree, proto_mac_mgmt_msg_ulmap_decoder, tvb, offset, tvb_len, "UL-MAP (%u bytes)", tvb_len); ulmap_tree = proto_item_add_subtree(ti, ett_ulmap); diff --git a/plugins/wimax/packet-wmx.c b/plugins/wimax/packet-wmx.c index 6e19f45479..1a76f3c13d 100644 --- a/plugins/wimax/packet-wmx.c +++ b/plugins/wimax/packet-wmx.c @@ -619,7 +619,7 @@ static gchar *tlv_val_5byte = "TLV value: %s (0x%08x...)"; /* return: */ /* pointer to a proto_tree */ /*************************************************************/ -proto_tree *add_tlv_subtree(tlv_info_t *this, gint idx, proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, gboolean little_endian) +proto_tree *add_tlv_subtree(tlv_info_t *this, gint idx, proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length _U_, gboolean little_endian) { /* Declare local variables */ proto_tree *tlv_tree; @@ -631,8 +631,6 @@ proto_tree *add_tlv_subtree(tlv_info_t *this, gint idx, proto_tree *tree, int hf guint32 tlv_value; gchar *hex_fmt; - UNREFERENCED_PARAMETER(length); - /* Retrieve the necessary TLV information */ tlv_val_offset = get_tlv_value_offset(this); start_of_tlv = start - tlv_val_offset; @@ -794,11 +792,8 @@ proto_tree *add_protocol_subtree(tlv_info_t *this, gint idx, proto_tree *tree, i /* WiMax protocol dissector */ -static void dissect_wimax(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) +static void dissect_wimax(tvbuff_t *tvb _U_, packet_info *pinfo, proto_tree *tree _U_) { - UNREFERENCED_PARAMETER(tvb); - UNREFERENCED_PARAMETER(tree); - /* display the WiMax protocol name */ col_set_str(pinfo->cinfo, COL_PROTOCOL, "WiMax"); /* Clear out stuff in the info column */ diff --git a/plugins/wimax/wimax_bits.h b/plugins/wimax/wimax_bits.h index 080dca9972..9ea26b2f38 100644 --- a/plugins/wimax/wimax_bits.h +++ b/plugins/wimax/wimax_bits.h @@ -222,11 +222,5 @@ #define NIB_TO_BYTE(n) ((n) / 2) #define NIB_TO_BIT(n) ((n) * 4) - - -#ifndef UNREFERENCED_PARAMETER -#define UNREFERENCED_PARAMETER(x) (x) = (x) -#endif - #endif diff --git a/plugins/wimax/wimax_compact_dlmap_ie_decoder.c b/plugins/wimax/wimax_compact_dlmap_ie_decoder.c index 5aea64fce0..f12665e5a1 100644 --- a/plugins/wimax/wimax_compact_dlmap_ie_decoder.c +++ b/plugins/wimax/wimax_compact_dlmap_ie_decoder.c @@ -981,15 +981,13 @@ guint wimax_compact_dlmap_ie_decoder(proto_tree *tree, packet_info *pinfo, tvbuf /*#define NUM_UL_AMC_SYMBOLS_SHIFT_1 0*/ /* Compact DL-MAP Format Configuration IE (6.3.2.3.43.2) decoder */ -static guint wimax_compact_dlmap_format_configuration_ie_decoder(proto_tree *tree, packet_info *pinfo, tvbuff_t *tvb, guint offset, guint nibble_offset) +static guint wimax_compact_dlmap_format_configuration_ie_decoder(proto_tree *tree, packet_info *pinfo _U_, tvbuff_t *tvb, guint offset, guint nibble_offset) { guint length = 0; guint dl_map_type, new_format_ind; guint dl_map_offset; guint32 tvb_value; - UNREFERENCED_PARAMETER(pinfo); - #ifdef DEBUG /* update the info column */ col_append_sep_str(pinfo->cinfo, COL_INFO, NULL, "Format Configuration IE"); @@ -1103,13 +1101,11 @@ static guint wimax_compact_dlmap_format_configuration_ie_decoder(proto_tree *tre } /* Compact DL-MAP Reduced CID IE (6.3.2.3.43.3) decoder */ -static guint wimax_compact_dlmap_rcid_ie_decoder(proto_tree *tree, packet_info *pinfo, tvbuff_t *tvb, guint offset, guint nibble_offset) +static guint wimax_compact_dlmap_rcid_ie_decoder(proto_tree *tree, packet_info *pinfo _U_, tvbuff_t *tvb, guint offset, guint nibble_offset) { guint length = 0; guint prefix; - UNREFERENCED_PARAMETER(pinfo); - #ifdef DEBUG /* update the info column */ col_append_sep_str(pinfo->cinfo, COL_INFO, NULL, "RCID IE"); @@ -1193,12 +1189,10 @@ static guint wimax_compact_dlmap_rcid_ie_decoder(proto_tree *tree, packet_info * } /* Compact DL-MAP HARQ Control IE (6.3.2.3.43.4) decoder */ -static guint wimax_compact_dlmap_harq_control_ie_decoder(proto_tree *tree, packet_info *pinfo, tvbuff_t *tvb, guint offset, guint nibble_offset) +static guint wimax_compact_dlmap_harq_control_ie_decoder(proto_tree *tree, packet_info *pinfo _U_, tvbuff_t *tvb, guint offset, guint nibble_offset) { guint byte, prefix, length = 0; - UNREFERENCED_PARAMETER(pinfo); - #ifdef DEBUG /* update the info column */ col_append_sep_str(pinfo->cinfo, COL_INFO, NULL, "HARQ Control IE"); @@ -1250,12 +1244,10 @@ static guint wimax_compact_dlmap_harq_control_ie_decoder(proto_tree *tree, packe } /* Compact DL-MAP CQICH Control IE (6.3.2.3.43.5) decoder */ -static guint wimax_compact_dlmap_cqich_control_ie_decoder(proto_tree *tree, packet_info *pinfo, tvbuff_t *tvb, guint offset, guint nibble_offset) +static guint wimax_compact_dlmap_cqich_control_ie_decoder(proto_tree *tree, packet_info *pinfo _U_, tvbuff_t *tvb, guint offset, guint nibble_offset) { guint byte, cqich_indicator, length = 0; - UNREFERENCED_PARAMETER(pinfo); - #ifdef DEBUG /* update the info column */ col_append_sep_str(pinfo->cinfo, COL_INFO, NULL, "CQICH Control IE"); @@ -1319,12 +1311,10 @@ static guint wimax_compact_dlmap_cqich_control_ie_decoder(proto_tree *tree, pack #define HARQ_MODE_SWITCH 1 /* Compact DL-MAP Extension IE (6.3.2.3.43.6.6) decoder */ -static guint wimax_cdlmap_extension_ie_decoder(proto_tree *tree, packet_info *pinfo, tvbuff_t *tvb, guint offset, guint nibble_offset) +static guint wimax_cdlmap_extension_ie_decoder(proto_tree *tree, packet_info *pinfo _U_, tvbuff_t *tvb, guint offset, guint nibble_offset) { guint tvb_value, dl_map_type, sub_type, length; - UNREFERENCED_PARAMETER(pinfo); - #ifdef DEBUG /* update the info column */ col_append_sep_str(pinfo->cinfo, COL_INFO, NULL, "DL-MAP Extension IE"); @@ -1418,13 +1408,11 @@ static guint wimax_cdlmap_extension_ie_decoder(proto_tree *tree, packet_info *pi #define UL_INTERFERENCE_AND_NOISE_LEVEL_IE 15 /* Extended DIUC IE (8.4.5.3.2) */ -guint wimax_extended_diuc_dependent_ie_decoder(proto_tree *tree, packet_info *pinfo, tvbuff_t *tvb, guint offset, guint nibble_offset) +guint wimax_extended_diuc_dependent_ie_decoder(proto_tree *tree, packet_info *pinfo _U_, tvbuff_t *tvb, guint offset, guint nibble_offset) { guint ext_diuc, length; guint8 byte; - UNREFERENCED_PARAMETER(pinfo); - /* get the first byte */ byte = tvb_get_guint8(tvb, offset); if(nibble_offset & 1) diff --git a/plugins/wimax/wimax_tlv.h b/plugins/wimax/wimax_tlv.h index 5228edb73b..ba3417dcc1 100644 --- a/plugins/wimax/wimax_tlv.h +++ b/plugins/wimax/wimax_tlv.h @@ -36,10 +36,6 @@ #define MAX_TLV_LEN 64000 -#ifndef UNREFERENCED_PARAMETER -#define UNREFERENCED_PARAMETER(x) (x) = (x) -#endif - typedef struct { guint8 valid; /* TLV info status: 0=invalid; 1=valid */ |