diff --git a/src/ap/drv_callbacks.c b/src/ap/drv_callbacks.c index 8d24e087e..4c0d0abac 100644 --- a/src/ap/drv_callbacks.c +++ b/src/ap/drv_callbacks.c @@ -86,8 +86,11 @@ int hostapd_notif_assoc(struct hostapd_data *hapd, const u8 *addr, sta->timeout_next = STA_NULLFUNC; } else { sta = ap_sta_add(hapd, addr); - if (sta == NULL) + if (sta == NULL) { + hostapd_drv_sta_disassoc(hapd, addr, + WLAN_REASON_DISASSOC_AP_BUSY); return -1; + } } sta->flags &= ~(WLAN_STA_WPS | WLAN_STA_MAYBE_WPS | WLAN_STA_WPS2);