aboutsummaryrefslogtreecommitdiffstats
path: root/src/ap
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2010-03-07 09:25:28 (GMT)
committerJouni Malinen <j@w1.fi>2010-03-07 09:25:28 (GMT)
commit70a8419f26e0b54c63f096bf1abe58e1f99202b5 (patch)
tree9523d68fd5dbaaf75a88b56d4ba2f7f335c49be9 /src/ap
parent7ab68865c03615be7a69daf219336a3c123b894c (diff)
downloadhostap-70a8419f26e0b54c63f096bf1abe58e1f99202b5.zip
hostap-70a8419f26e0b54c63f096bf1abe58e1f99202b5.tar.gz
hostap-70a8419f26e0b54c63f096bf1abe58e1f99202b5.tar.bz2
Avoid crash after driver init failure
hostapd_flush_old_stations() needs to check whether the driver initialization was successful since it gets called on an error path.
Diffstat (limited to 'src/ap')
-rw-r--r--src/ap/hostapd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ap/hostapd.c b/src/ap/hostapd.c
index 8bf92b8..2c0c87d 100644
--- a/src/ap/hostapd.c
+++ b/src/ap/hostapd.c
@@ -299,7 +299,7 @@ static int hostapd_flush_old_stations(struct hostapd_data *hapd)
{
int ret = 0;
- if (hostapd_drv_none(hapd))
+ if (hostapd_drv_none(hapd) || hapd->drv_priv == NULL)
return 0;
wpa_printf(MSG_DEBUG, "Flushing old station entries");