summaryrefslogtreecommitdiffstats
path: root/contrib
diff options
context:
space:
mode:
authorwpaul <wpaul@FreeBSD.org>2005-10-20 16:31:54 +0000
committerwpaul <wpaul@FreeBSD.org>2005-10-20 16:31:54 +0000
commit34dbcde8dfa5b3d152d250b6d69965e001238e49 (patch)
tree03113f970a94acd34d130c12372c761772949090 /contrib
parent6a5bf1d411099addfa3fcb01da656570ab660413 (diff)
downloadFreeBSD-src-34dbcde8dfa5b3d152d250b6d69965e001238e49.zip
FreeBSD-src-34dbcde8dfa5b3d152d250b6d69965e001238e49.tar.gz
Import a fixed version of driver_ndis.c from the vendor. The existing
version has a bug where it fails to properly cancel the polling loop that periodically queries the BSSID (this is done to detect the association/disassociation state). The timeout is supposed to fire once a second, but the eloop_cancel_timeout() call uses a different 'user data' value than what was passed to eloop_register_timeout(), so cancelling the timeouts fails. This results in an additional timeout being created each time an EAPOL packet is received, which can lead to dozens of unwanted timeouts firing every second instead of just one.
Diffstat (limited to 'contrib')
-rw-r--r--contrib/wpa_supplicant/driver_ndis.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/contrib/wpa_supplicant/driver_ndis.c b/contrib/wpa_supplicant/driver_ndis.c
index 678d228..1dba95a 100644
--- a/contrib/wpa_supplicant/driver_ndis.c
+++ b/contrib/wpa_supplicant/driver_ndis.c
@@ -1023,7 +1023,7 @@ static void wpa_driver_ndis_poll_timeout(void *eloop_ctx, void *timeout_ctx)
static void wpa_driver_ndis_poll(void *priv)
{
struct wpa_driver_ndis_data *drv = priv;
- eloop_cancel_timeout(wpa_driver_ndis_poll_timeout, drv, drv->ctx);
+ eloop_cancel_timeout(wpa_driver_ndis_poll_timeout, drv, NULL);
wpa_driver_ndis_poll_timeout(drv, NULL);
}
@@ -1546,7 +1546,7 @@ static void * wpa_driver_ndis_init(void *ctx, const char *ifname)
static void wpa_driver_ndis_deinit(void *priv)
{
struct wpa_driver_ndis_data *drv = priv;
- eloop_cancel_timeout(wpa_driver_ndis_poll_timeout, drv, drv->ctx);
+ eloop_cancel_timeout(wpa_driver_ndis_poll_timeout, drv, NULL);
wpa_driver_ndis_flush_pmkid(drv);
wpa_driver_ndis_disconnect(drv);
if (wpa_driver_ndis_radio_off(drv) < 0) {
OpenPOWER on IntegriCloud