aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2016-05-22 13:23:28 (GMT)
committerJouni Malinen <j@w1.fi>2016-05-22 13:23:28 (GMT)
commite1ae2876d5851658feb91d0b3616738722edb05c (patch)
treecc2e8b1ab5680534cf8cfb4bf5544804f2f7f106 /wpa_supplicant
parenta1703947b134eea173e85e7030ad5527f2f8361f (diff)
downloadhostap-e1ae2876d5851658feb91d0b3616738722edb05c.zip
hostap-e1ae2876d5851658feb91d0b3616738722edb05c.tar.gz
hostap-e1ae2876d5851658feb91d0b3616738722edb05c.tar.bz2
scan: Clean up code a bit - ssid cannot be NULL here
wpa_s->current_ssid is set to a non-NULL ssid pointer value here, so there is no need for the extra if statement. Signed-off-by: Jouni Malinen <j@w1.fi>
Diffstat (limited to 'wpa_supplicant')
-rw-r--r--wpa_supplicant/scan.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/wpa_supplicant/scan.c b/wpa_supplicant/scan.c
index 8dab442..bfee756 100644
--- a/wpa_supplicant/scan.c
+++ b/wpa_supplicant/scan.c
@@ -36,8 +36,7 @@ static void wpa_supplicant_gen_assoc_event(struct wpa_supplicant *wpa_s)
if (wpa_s->current_ssid == NULL) {
wpa_s->current_ssid = ssid;
- if (wpa_s->current_ssid != NULL)
- wpas_notify_network_changed(wpa_s);
+ wpas_notify_network_changed(wpa_s);
}
wpa_supplicant_initiate_eapol(wpa_s);
wpa_dbg(wpa_s, MSG_DEBUG, "Already associated with a configured "