[PATCH 1/2] AP: Remove redundant condition for STA expiration

Masashi Honma masashi.honma
Fri Jan 16 03:00:57 PST 2015


This condition is always true. Because of surrounding if.

Signed-off-by: Masashi Honma <masashi.honma at gmail.com>
---
 src/ap/sta_info.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/ap/sta_info.c b/src/ap/sta_info.c
index 1c2197a..b6a7e23 100644
--- a/src/ap/sta_info.c
+++ b/src/ap/sta_info.c
@@ -370,8 +370,7 @@ void ap_handle_timer(void *eloop_ctx, void *timeout_ctx)
 			 * but do not disconnect the station now.
 			 */
 			next_time = hapd->conf->ap_max_inactivity + fuzz;
-		} else if (inactive_sec < hapd->conf->ap_max_inactivity &&
-			   sta->flags & WLAN_STA_ASSOC) {
+		} else if (inactive_sec < hapd->conf->ap_max_inactivity) {
 			/* station activity detected; reset timeout state */
 			wpa_msg(hapd->msg_ctx, MSG_DEBUG,
 				"Station " MACSTR " has been active %is ago",
-- 
1.9.1




More information about the Hostap mailing list