diff options
author | Dmitry Shmidt <dimitrysh@google.com> | 2011-11-25 22:00:43 +0200 |
---|---|---|
committer | Arik Nemtsov <arik@wizery.com> | 2012-08-02 13:03:58 +0300 |
commit | 7c2a971672e9b5852b39e8cdaaa6788ac238b97b (patch) | |
tree | aaa55ff1b52b9b8f4eaf455241899de32f591b82 /src/drivers | |
parent | 2da8008ec384f4e5e0b4970a29f25bfd0b378d14 (diff) | |
download | external_wpa_supplicant_8_ti-7c2a971672e9b5852b39e8cdaaa6788ac238b97b.zip external_wpa_supplicant_8_ti-7c2a971672e9b5852b39e8cdaaa6788ac238b97b.tar.gz external_wpa_supplicant_8_ti-7c2a971672e9b5852b39e8cdaaa6788ac238b97b.tar.bz2 |
Android: wext: Suppress additional DISASSOCIATE events
Change-Id: Id65428908bca59e71a3ab479b63d992eff96e433
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Diffstat (limited to 'src/drivers')
-rw-r--r-- | src/drivers/driver_wext.c | 15 | ||||
-rw-r--r-- | src/drivers/driver_wext.h | 1 |
2 files changed, 16 insertions, 0 deletions
diff --git a/src/drivers/driver_wext.c b/src/drivers/driver_wext.c index 73322b3..5bf9b7c 100644 --- a/src/drivers/driver_wext.c +++ b/src/drivers/driver_wext.c @@ -487,10 +487,20 @@ static void wpa_driver_wext_event_wireless(struct wpa_driver_wext_data *drv, drv->assoc_req_ies = NULL; os_free(drv->assoc_resp_ies); drv->assoc_resp_ies = NULL; +#ifdef ANDROID + if (!drv->skip_disconnect) { + drv->skip_disconnect = 1; +#endif /* ANDROID */ wpa_supplicant_event(drv->ctx, EVENT_DISASSOC, NULL); +#ifdef ANDROID + } +#endif /* ANDROID */ } else { +#ifdef ANDROID + drv->skip_disconnect = 0; +#endif /* ANDROID */ wpa_driver_wext_event_assoc_ies(drv); wpa_supplicant_event(drv->ctx, EVENT_ASSOC, NULL); @@ -872,6 +882,7 @@ void * wpa_driver_wext_init(void *ctx, const char *ifname) #ifdef ANDROID drv->errors = 0; drv->driver_is_started = TRUE; + drv->skip_disconnect = 0; drv->bgscan_enabled = 0; #endif /* ANDROID */ @@ -2081,6 +2092,10 @@ int wpa_driver_wext_associate(void *priv, wpa_printf(MSG_DEBUG, "%s", __FUNCTION__); +#ifdef ANDROID + drv->skip_disconnect = 0; +#endif /* ANDROID */ + if (drv->cfg80211) { /* * Stop cfg80211 from trying to associate before we are done diff --git a/src/drivers/driver_wext.h b/src/drivers/driver_wext.h index c4a5bc9..7e0b28b 100644 --- a/src/drivers/driver_wext.h +++ b/src/drivers/driver_wext.h @@ -48,6 +48,7 @@ struct wpa_driver_wext_data { #ifdef ANDROID int errors; int driver_is_started; + int skip_disconnect; int bgscan_enabled; #endif /* ANDROID */ }; |