Staging: rtl8192e: Fix else is not useful warning style
authorMahati Chamarthy <mahati.chamarthy@gmail.com>
Sun, 21 Sep 2014 19:51:48 +0000 (01:21 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 23 Sep 2014 20:51:45 +0000 (13:51 -0700)
This fixes the following checkpatch.pl warnings:
WARNING: else is not generally useful after a break or return

Signed-off-by: Mahati Chamarthy <mahati.chamarthy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8192e/rtllib_softmac.c

index cbe1d354907af1e0671f321a8a6f69809dad1711..abb6729ae2792f0a0f39d698741394e69bc77811 100644 (file)
@@ -1161,8 +1161,7 @@ inline int SecIsInPMKIDList(struct rtllib_device *ieee, u8 *bssid)
                if ((ieee->PMKIDList[i].bUsed) &&
                   (memcmp(ieee->PMKIDList[i].Bssid, bssid, ETH_ALEN) == 0))
                        break;
-               else
-                       i++;
+               i++;
        } while (i < NUM_PMKID_CACHE);
 
        if (i == NUM_PMKID_CACHE)
@@ -2261,14 +2260,13 @@ inline int rtllib_rx_assoc_resp(struct rtllib_device *ieee, struct sk_buff *skb,
                                                        network, rx_stats)) {
                                        kfree(network);
                                        return 1;
-                               } else {
-                                       memcpy(ieee->pHTInfo->PeerHTCapBuf,
-                                              network->bssht.bdHTCapBuf,
-                                              network->bssht.bdHTCapLen);
-                                       memcpy(ieee->pHTInfo->PeerHTInfoBuf,
-                                              network->bssht.bdHTInfoBuf,
-                                              network->bssht.bdHTInfoLen);
                                }
+                               memcpy(ieee->pHTInfo->PeerHTCapBuf,
+                                      network->bssht.bdHTCapBuf,
+                                      network->bssht.bdHTCapLen);
+                               memcpy(ieee->pHTInfo->PeerHTInfoBuf,
+                                      network->bssht.bdHTInfoBuf,
+                                      network->bssht.bdHTInfoLen);
                                if (ieee->handle_assoc_response != NULL)
                                        ieee->handle_assoc_response(ieee->dev,
                                                 (struct rtllib_assoc_response_frame *)header,