diff mbox

AP: Remove unneeded check for 'added_unassociated'

Message ID 1503333385-15051-1-git-send-email-andrei.otcheretianski@intel.com
State Accepted
Headers show

Commit Message

Andrei Otcheretianski Aug. 21, 2017, 4:36 p.m. UTC
From: Ilan Peer <ilan.peer@intel.com>

In fils_hlp_finish_assoc() the station is already added to the
driver so it is not needed to check the 'added_unassociated'
flag.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
---
 src/ap/ieee802_11.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

Comments

Jouni Malinen Sept. 25, 2017, 8:38 p.m. UTC | #1
On Mon, Aug 21, 2017 at 07:36:21PM +0300, Andrei Otcheretianski wrote:
> In fils_hlp_finish_assoc() the station is already added to the
> driver so it is not needed to check the 'added_unassociated'
> flag.

Thanks, applied.
diff mbox

Patch

diff --git a/src/ap/ieee802_11.c b/src/ap/ieee802_11.c
index 6f51214..f061839 100644
--- a/src/ap/ieee802_11.c
+++ b/src/ap/ieee802_11.c
@@ -2837,14 +2837,11 @@  void fils_hlp_finish_assoc(struct hostapd_data *hapd, struct sta_info *sta)
 	sta->hlp_dhcp_discover = NULL;
 
 	/*
-	 * Remove the station in case tranmission of a success response fails
-	 * (the STA was added associated to the driver) or if the station was
-	 * previously added unassociated.
+	 * Remove the station in case transmission of a success response fails.
+	 * At this point the station was already added associated to the driver.
 	 */
-	if (reply_res != WLAN_STATUS_SUCCESS || sta->added_unassoc) {
+	if (reply_res != WLAN_STATUS_SUCCESS)
 		hostapd_drv_sta_remove(hapd, sta->addr);
-		sta->added_unassoc = 0;
-	}
 }