diff options
author | Alexis La Goutte <alexis.lagoutte@gmail.com> | 2017-03-05 19:38:59 +0100 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2017-03-05 22:39:13 +0000 |
commit | c1e6724cf6938de24ddfbcb0227aad5822a80c2d (patch) | |
tree | d2a36eeb67d9771ab7649b98272db23287ddbdad /epan | |
parent | 70e04f3f4c1a290ce8834bb7f9773d4f644db5e8 (diff) |
dissectors: fix this statement may fall through [-Werror=implicit-fallthrough=] found by gcc7
Change-Id: Iba6238988ded675cba328ab512232d1919d93b4a
Reviewed-on: https://code.wireshark.org/review/20415
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan')
-rw-r--r-- | epan/dissectors/asn1/gsm_map/packet-gsm_map-template.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-atalk.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-dof.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-edonkey.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-giop.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-gsm_map.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-ieee802154.c | 1 | ||||
-rw-r--r-- | epan/dissectors/packet-infiniband.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-isns.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-l2tp.c | 1 | ||||
-rw-r--r-- | epan/dissectors/packet-nas_eps.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-nbifom.c | 1 | ||||
-rw-r--r-- | epan/dissectors/packet-ncp.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-ntp.c | 1 | ||||
-rw-r--r-- | epan/dissectors/packet-pw-atm.c | 1 | ||||
-rw-r--r-- | epan/dissectors/packet-rip.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-scsi-osd.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-tn3270.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-ua3g.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-ucp.c | 1 | ||||
-rw-r--r-- | epan/dissectors/packet-x11.c | 2 |
21 files changed, 23 insertions, 13 deletions
diff --git a/epan/dissectors/asn1/gsm_map/packet-gsm_map-template.c b/epan/dissectors/asn1/gsm_map/packet-gsm_map-template.c index ce83d1c861..8c72ed180f 100644 --- a/epan/dissectors/asn1/gsm_map/packet-gsm_map-template.c +++ b/epan/dissectors/asn1/gsm_map/packet-gsm_map-template.c @@ -914,12 +914,12 @@ const gchar* gsm_map_opr_code(guint32 val, proto_item *item) { case 44: /*mt-forwardSM*/ /* FALLTHRU */ case 46: /*mo-forwardSM*/ - /* FALLTHRU */ if (application_context_version < 3) { proto_item_set_text(item, "%s (%d)", val_to_str_const(val, gsm_map_V1V2_opr_code_strings, "Unknown GSM-MAP opcode"), val); return val_to_str_const(val, gsm_map_V1V2_opr_code_strings, "Unknown GSM-MAP opcode"); } /* Else use the default map operation translation */ + /* FALLTHRU */ default: return val_to_str_ext_const(val, &gsm_old_GSMMAPOperationLocalvalue_vals_ext, "Unknown GSM-MAP opcode"); break; diff --git a/epan/dissectors/packet-atalk.c b/epan/dissectors/packet-atalk.c index 03278d0fd0..c6ff2013a1 100644 --- a/epan/dissectors/packet-atalk.c +++ b/epan/dissectors/packet-atalk.c @@ -1130,7 +1130,7 @@ dissect_asp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data) case ASPFUNC_TICKLE: case ASPFUNC_WRTCONT: proto_tree_add_item(asp_tree, hf_asp_zero_value, tvb, offset, 4, ENC_NA); - /* fall */ + /* FALL THROUGH */ case ASPFUNC_ATTN: /* FIXME capture and spec disagree */ default: proto_item_set_len(asp_tree, 4); diff --git a/epan/dissectors/packet-dof.c b/epan/dissectors/packet-dof.c index 8ce73a8b12..9f48023f60 100644 --- a/epan/dissectors/packet-dof.c +++ b/epan/dissectors/packet-dof.c @@ -9441,7 +9441,7 @@ static int dissect_tep(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void } } - /* FALL THROUGH TO REQUEST */ + /* FALL THROUGH */ case TEP_PDU_REQUEST: diff --git a/epan/dissectors/packet-edonkey.c b/epan/dissectors/packet-edonkey.c index f9a848b959..8a600b9c98 100644 --- a/epan/dissectors/packet-edonkey.c +++ b/epan/dissectors/packet-edonkey.c @@ -2952,7 +2952,7 @@ static int dissect_edonkey_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree dissector = dissect_edonkey_tcp_message; break; } - + /* FALL THROUGH */ default: message_name = "Unknown"; dissector = NULL; diff --git a/epan/dissectors/packet-giop.c b/epan/dissectors/packet-giop.c index ff5ece403e..04e307c4b5 100644 --- a/epan/dissectors/packet-giop.c +++ b/epan/dissectors/packet-giop.c @@ -4033,7 +4033,7 @@ dissect_reply_body (tvbuff_t *tvb, guint offset, packet_info *pinfo, */ - + /* FALL THROUGH */ case NO_EXCEPTION: diff --git a/epan/dissectors/packet-gsm_map.c b/epan/dissectors/packet-gsm_map.c index b797053648..5637772167 100644 --- a/epan/dissectors/packet-gsm_map.c +++ b/epan/dissectors/packet-gsm_map.c @@ -21260,12 +21260,12 @@ const gchar* gsm_map_opr_code(guint32 val, proto_item *item) { case 44: /*mt-forwardSM*/ /* FALLTHRU */ case 46: /*mo-forwardSM*/ - /* FALLTHRU */ if (application_context_version < 3) { proto_item_set_text(item, "%s (%d)", val_to_str_const(val, gsm_map_V1V2_opr_code_strings, "Unknown GSM-MAP opcode"), val); return val_to_str_const(val, gsm_map_V1V2_opr_code_strings, "Unknown GSM-MAP opcode"); } /* Else use the default map operation translation */ + /* FALLTHRU */ default: return val_to_str_ext_const(val, &gsm_old_GSMMAPOperationLocalvalue_vals_ext, "Unknown GSM-MAP opcode"); break; diff --git a/epan/dissectors/packet-ieee802154.c b/epan/dissectors/packet-ieee802154.c index 249410103f..c7e9b3fc42 100644 --- a/epan/dissectors/packet-ieee802154.c +++ b/epan/dissectors/packet-ieee802154.c @@ -1654,6 +1654,7 @@ dissect_ieee802154_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, g /* Try heuristic dissection. */ if (dissector_try_heuristic(ieee802154_heur_subdissector_list, payload_tvb, pinfo, tree, &hdtbl_entry, packet)) break; /* Fall-through to dump undissectable payloads. */ + /* FALL THROUGH */ default: /* Could not subdissect, call the data dissector instead. */ call_data_dissector(payload_tvb, pinfo, tree); diff --git a/epan/dissectors/packet-infiniband.c b/epan/dissectors/packet-infiniband.c index 0e4fd0b1c7..2625d00c68 100644 --- a/epan/dissectors/packet-infiniband.c +++ b/epan/dissectors/packet-infiniband.c @@ -1746,6 +1746,7 @@ skip_lrh: } } /* otherwise fall through and start parsing BTH */ + /* FALL THROUGH */ case IBA_LOCAL: { proto_item *base_transport_header_item; proto_tree *base_transport_header_tree; @@ -5385,6 +5386,7 @@ skip_lrh: * Fall through switch and start parsing Local Headers and BTH * } */ + /* FALL THROUGH */ case IBA_LOCAL: bthFollows = TRUE; diff --git a/epan/dissectors/packet-isns.c b/epan/dissectors/packet-isns.c index 1de7c1c0b9..800392a27c 100644 --- a/epan/dissectors/packet-isns.c +++ b/epan/dissectors/packet-isns.c @@ -654,7 +654,7 @@ dissect_isns_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data /* Fall Thru if there are attributes */ if (tvb_reported_length_remaining(tvb, offset) == 0) return tvb_captured_length(tvb); - + /* FALL THROUGH */ /* Messages */ case ISNS_FUNC_DEVATTRREG: case ISNS_FUNC_DEVATTRQRY: diff --git a/epan/dissectors/packet-l2tp.c b/epan/dissectors/packet-l2tp.c index 0e9e44eee1..6ba9c356a6 100644 --- a/epan/dissectors/packet-l2tp.c +++ b/epan/dissectors/packet-l2tp.c @@ -1436,6 +1436,7 @@ static l2tpv3_session_t *store_l2_sublayer(l2tpv3_session_t *_session, case MESSAGE_TYPE_ICCN: case MESSAGE_TYPE_OCCN: session->lcce1.l2_specific = result; + /* FALL THROUGH */ case MESSAGE_TYPE_ICRP: case MESSAGE_TYPE_OCRP: session->lcce2.l2_specific = result; diff --git a/epan/dissectors/packet-nas_eps.c b/epan/dissectors/packet-nas_eps.c index 25f5db5abc..add49f55c1 100644 --- a/epan/dissectors/packet-nas_eps.c +++ b/epan/dissectors/packet-nas_eps.c @@ -5651,6 +5651,7 @@ dissect_nas_eps_plain(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* call_dissector(gsm_a_dtap_handle, new_tvb,pinfo, nas_eps_tree); break; } /* else fall through default */ + /* FALL THROUGH */ default: proto_tree_add_expert_format(nas_eps_tree, pinfo, &ei_nas_eps_unknown_pd, tvb, offset, -1, "Not a NAS EPS PD %u (%s)", pd, val_to_str_const(pd, protocol_discriminator_vals, "Unknown")); @@ -5803,6 +5804,7 @@ dissect_nas_eps(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data call_dissector(gsm_a_dtap_handle, new_tvb, pinfo, nas_eps_tree); break; } /* else fall through default */ + /* FALL THROUGH */ default: proto_tree_add_expert_format(nas_eps_tree, pinfo, &ei_nas_eps_unknown_pd, tvb, offset, -1, "Not a NAS EPS PD %u (%s)", pd, val_to_str_const(pd, protocol_discriminator_vals, "Unknown")); diff --git a/epan/dissectors/packet-nbifom.c b/epan/dissectors/packet-nbifom.c index f3ee117514..2df4557b2d 100644 --- a/epan/dissectors/packet-nbifom.c +++ b/epan/dissectors/packet-nbifom.c @@ -326,6 +326,7 @@ dissect_nbifom(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _ if (pinfo->link_dir == P2P_DIR_DL) { break; } /* else fall through case 4 */ + /* FALL THROUGH */ case 4: dissect_nbifom_routing_rules(tvb, pinfo, subtree, offset, param_contents_len); offset += param_contents_len; diff --git a/epan/dissectors/packet-ncp.c b/epan/dissectors/packet-ncp.c index 67aadbdfda..322f02df09 100644 --- a/epan/dissectors/packet-ncp.c +++ b/epan/dissectors/packet-ncp.c @@ -1135,7 +1135,7 @@ dissect_ncp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, break; } } - /* otherwise fall through */ + /* fall through */ case NCP_POSITIVE_ACK: /* Positive Acknowledgement */ case NCP_SERVICE_REQUEST: /* Server NCP Request */ diff --git a/epan/dissectors/packet-ntp.c b/epan/dissectors/packet-ntp.c index 3ed1dbbfe4..3ecfe1901b 100644 --- a/epan/dissectors/packet-ntp.c +++ b/epan/dissectors/packet-ntp.c @@ -1181,6 +1181,7 @@ dissect_ntp_ctrl(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *ntp_tree) * then data part could be the same as if opcode is NTPCTRL_OP_READVAR * --> so, no "break" here! */ + /* FALL THROUGH */ case NTPCTRL_OP_READVAR: case NTPCTRL_OP_WRITEVAR: case NTPCTRL_OP_READCLOCK: diff --git a/epan/dissectors/packet-pw-atm.c b/epan/dissectors/packet-pw-atm.c index 6a25be182d..e180a73896 100644 --- a/epan/dissectors/packet-pw-atm.c +++ b/epan/dissectors/packet-pw-atm.c @@ -1383,6 +1383,7 @@ dissect_cell_header(tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree, void case PWATM_MODE_AAL5_SDU: DISSECTOR_ASSERT(pd->submode == PWATM_SUBMODE_ADMIN_CELL); /*fallthrough for ATM admin cell submode only*/ + /* FALL THROUGH */ case PWATM_MODE_N1_CW: case PWATM_MODE_N1_NOCW: pd->vpi = (tvb_get_ntohs (tvb, 0) >> 4); diff --git a/epan/dissectors/packet-rip.c b/epan/dissectors/packet-rip.c index 9cd2108b36..f52a74852b 100644 --- a/epan/dissectors/packet-rip.c +++ b/epan/dissectors/packet-rip.c @@ -229,7 +229,7 @@ dissect_rip(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_) } if(is_md5_auth && tvb_reported_length_remaining(tvb, offset) == 20) break; - /* Intentional fall through: auth Entry MUST be the first! */ + /* Intentional fall through */ /* auth Entry MUST be the first! */ default: proto_tree_add_expert_format(rip_tree, pinfo, &ei_rip_unknown_address_family, tvb, offset, RIP_ENTRY_LENGTH, "Unknown address family %u", family); diff --git a/epan/dissectors/packet-scsi-osd.c b/epan/dissectors/packet-scsi-osd.c index 95456957bc..8d1b86ac61 100644 --- a/epan/dissectors/packet-scsi-osd.c +++ b/epan/dissectors/packet-scsi-osd.c @@ -570,7 +570,7 @@ dissect_osd_attributes_list(packet_info *pinfo, tvbuff_t *tvb, int offset, /* user object id */ dissect_osd_user_object_id(tvb, offset, tt); offset += 8; - /* fallthrough to the next case */ + /* fallthrough */ case 0x09: /* retrieved/set attributes OSD-1: 7.1.3.3 OSD-2: 7.1.4.3*/ offset = dissect_osd_attribute_list_entry(pinfo, tvb, tt, ti, offset, lun_info, osd2); break; diff --git a/epan/dissectors/packet-tn3270.c b/epan/dissectors/packet-tn3270.c index 9c4e5986ae..539d686456 100644 --- a/epan/dissectors/packet-tn3270.c +++ b/epan/dissectors/packet-tn3270.c @@ -5186,7 +5186,7 @@ dissect_inbound_stream(proto_tree *tn3270_tree, packet_info *pinfo, tvbuff_t *tv /* XXX: Is this the correct/complete set of AID bytes for this case ? */ if (tvb_reported_length_remaining(tvb, offset) <= 0) break; - /* fall into next */ + /* FALL THROUGH */ case AID_READ_PARTITION_AID: case AID_NO_AID_GENERATED: case AID_NO_AID_GENERATED_PRINTER_ONLY: diff --git a/epan/dissectors/packet-ua3g.c b/epan/dissectors/packet-ua3g.c index 979566ec08..1a8370e73f 100644 --- a/epan/dissectors/packet-ua3g.c +++ b/epan/dissectors/packet-ua3g.c @@ -3233,8 +3233,8 @@ decode_cs_ip_device_routing(proto_tree *tree _U_, tvbuff_t *tvb, { /* XXX: What is the point of this assignment? */ framing_rtp = tvb_get_guint8(tvb, offset + 3); - /* FALLTHROUGH */ } + /* FALLTHROUGH */ case 0x01: /* Date Of End Of Communication */ case 0x02: /* Node Number */ case 0x03: /* Ticket Protocol Version */ diff --git a/epan/dissectors/packet-ucp.c b/epan/dissectors/packet-ucp.c index 6647f04220..37eeb7d22e 100644 --- a/epan/dissectors/packet-ucp.c +++ b/epan/dissectors/packet-ucp.c @@ -999,6 +999,7 @@ ucp_handle_mt(proto_tree *tree, packet_info* pinfo, tvbuff_t *tvb, int *offset) case '4': /* TMsg, no of bits */ ucp_handle_string(tree, tvb, hf_ucp_parm_NB, offset); /* fall through here for the data piece */ + /* FALLTHROUGH */ case '2': ucp_handle_data(tree, tvb, hf_ucp_data_section, offset); break; diff --git a/epan/dissectors/packet-x11.c b/epan/dissectors/packet-x11.c index ebad4a1967..f1fa647f9d 100644 --- a/epan/dissectors/packet-x11.c +++ b/epan/dissectors/packet-x11.c @@ -3422,7 +3422,7 @@ static void dissect_x11_request(tvbuff_t *tvb, packet_info *pinfo, } /* QueryExtension expects a reply, fall through */ - + /* FALLTHROUGH */ case X_AllocColor: case X_AllocColorCells: case X_AllocColorPlanes: |