lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1504249373-8143-1-git-send-email-jananis37@gmail.com>
Date:   Fri,  1 Sep 2017 12:32:53 +0530
From:   Janani Sankara Babu <jananis37@...il.com>
To:     gregkh@...uxfoundation.org
Cc:     insafonov@...il.com, gs051095@...il.com,
        devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org,
        Janani Sankara Babu <jananis37@...il.com>
Subject: [PATCH V2] staging:rtl8188eu:core Fix remove unneccessary else block

This patch removes the unwanted braces and else statement inside the
function 'SecIsInPMKIDList'

Signed-off-by: Janani Sankara Babu <jananis37@...il.com>
---
Changelog
V1 : Removed the else statement & Curly braces in If statement 
V2 : Removed the comment and added preincrement of i inside the while loop
 drivers/staging/rtl8188eu/core/rtw_mlme.c | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)

diff --git a/drivers/staging/rtl8188eu/core/rtw_mlme.c b/drivers/staging/rtl8188eu/core/rtw_mlme.c
index d3668ca..9c2571d 100644
--- a/drivers/staging/rtl8188eu/core/rtw_mlme.c
+++ b/drivers/staging/rtl8188eu/core/rtw_mlme.c
@@ -1708,14 +1708,9 @@ static int SecIsInPMKIDList(struct adapter *Adapter, u8 *bssid)
 
 	do {
 		if ((psecuritypriv->PMKIDList[i].bUsed) &&
-		    (!memcmp(psecuritypriv->PMKIDList[i].Bssid, bssid, ETH_ALEN))) {
+		    (!memcmp(psecuritypriv->PMKIDList[i].Bssid, bssid, ETH_ALEN)))
 			break;
-		} else {
-			i++;
-			/* continue; */
-		}
-
-	} while (i < NUM_PMKID_CACHE);
+	} while (++i < NUM_PMKID_CACHE);
 
 	if (i == NUM_PMKID_CACHE)
 		i = -1;/*  Could not find. */
-- 
1.9.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ