nl80211: Generate 802.11b mode based on 802.11g information
[wpasupplicant] / hostapd / hostapd.c
index 681ebbf..225ad3a 100644 (file)
@@ -254,7 +254,8 @@ void hostapd_new_assoc_sta(struct hostapd_data *hapd, struct sta_info *sta,
        /* Start IEEE 802.1X authentication process for new stations */
        ieee802_1x_new_station(hapd, sta);
        if (reassoc) {
-               if (sta->auth_alg != WLAN_AUTH_FT)
+               if (sta->auth_alg != WLAN_AUTH_FT &&
+                   !(sta->flags & (WLAN_STA_WPS | WLAN_STA_MAYBE_WPS)))
                        wpa_auth_sm_event(sta->wpa_sm, WPA_REAUTH);
        } else
                wpa_auth_sta_associated(hapd->wpa_auth, sta->wpa_sm);
@@ -1554,6 +1555,7 @@ static int setup_interface(struct hostapd_iface *iface)
                       hapd->iconf->channel, freq);
 
                if (hostapd_set_freq(hapd, hapd->iconf->hw_mode, freq,
+                                    hapd->iconf->ieee80211n,
                                     hapd->iconf->secondary_channel)) {
                        printf("Could not set channel for kernel driver\n");
                        return -1;