staging: rtl8188eu: Fix fall-through warnings for Clang
PATCH 1/1 staging: rtl8188eu: Fix fall-through warnings for Clang
In preparation to enable -Wimplicit-fallthrough for Clang, fix multiple warnings by explicitly adding multiple break statements instead of just letting the code fall through to the next case.
---
JFYI: We had thousands of these sorts of warnings and now we are down
to just 25 in linux-next. These are some of those last remaining warnings.
drivers/staging/rtl8188eu/core/rtw_mlme_ext.c | 1 + drivers/staging/rtl8188eu/core/rtw_wlan_util.c | 2 ++ 2 files changed, 3 insertions(+)
drivers/staging/rtl8188eu/core/rtw_mlme_ext.c +1 -0
@@ -3378,6 +3378,7 @@ static unsigned int OnAssocRsp(struct adapter *padapter,break ;case WLAN_EID_ERP_INFO :ERP_IE_handler (padapter, pIE); +break ;default :break ; }
drivers/staging/rtl8188eu/core/rtw_wlan_util.c +2 -0
@@ -1029,6 +1029,7 @@ unsigned int is_ap_in_tkip(struct adapter *padapter)case WLAN_EID_RSN :if (!memcmp ((pIE->data +8 ),RSN_TKIP_CIPHER ,4 ))return true; +break ;default :break ; }
@@ -1226,6 +1227,7 @@ unsigned char check_assoc_AP(u8 *pframe, uint len) }else {break ; } +break ;default :break ;
Signature · 1 line
2.27.0
Quoted 6 lines · Gustavo A. R. Silva
In preparation to enable -Wimplicit-fallthrough for Clang, fix multiple warnings by explicitly adding multiple break statements instead of just letting the code fall through to the next case.
Reviewed-by Kees Cook <[email protected]>
Signature · 1 line
Kees Cook