staging: r8188eu: remove unnecessary label
authorMartin Kaiser <martin@kaiser.cx>
Mon, 24 Oct 2022 08:14:13 +0000 (10:14 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 25 Oct 2022 17:19:38 +0000 (19:19 +0200)
Remove a label on OnAuthClient that just calls return. We can return
directly instead of jumping to this label.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150
Link: https://lore.kernel.org/r/20221024081417.66441-14-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/r8188eu/core/rtw_mlme_ext.c

index d89f494..e2e7c35 100644 (file)
@@ -823,7 +823,7 @@ static void OnAuthClient(struct adapter *padapter, struct recv_frame *precv_fram
                }
 
                set_link_timer(pmlmeext, 1);
-               goto authclnt_fail;
+               return;
        }
 
        if (seq == 2) {
@@ -833,7 +833,7 @@ static void OnAuthClient(struct adapter *padapter, struct recv_frame *precv_fram
                                pkt_len - WLAN_HDR_A3_LEN - _AUTH_IE_OFFSET_);
 
                        if (!p)
-                               goto authclnt_fail;
+                               return;
 
                        memcpy((void *)(pmlmeinfo->chg_txt), (void *)(p + 2), len);
                        pmlmeinfo->auth_seq = 3;
@@ -849,18 +849,16 @@ static void OnAuthClient(struct adapter *padapter, struct recv_frame *precv_fram
                if (pmlmeinfo->auth_algo == dot11AuthAlgrthm_Shared)
                        go2asoc = 1;
                else
-                       goto authclnt_fail;
+                       return;
        } else {
                /*  this is also illegal */
-               goto authclnt_fail;
+               return;
        }
 
        if (go2asoc) {
                start_clnt_assoc(padapter);
                return;
        }
-authclnt_fail:
-       return;
 }
 
 static void UpdateBrateTbl(u8 *mbrate)