Module Name:    src
Committed By:   roy
Date:           Wed Mar 23 08:51:02 UTC 2016

Modified Files:
        src/external/bsd/wpa/dist/src/drivers: driver_bsd.c

Log Message:
Only down the interface once we are sure we can work with it.


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/external/bsd/wpa/dist/src/drivers/driver_bsd.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/bsd/wpa/dist/src/drivers/driver_bsd.c
diff -u src/external/bsd/wpa/dist/src/drivers/driver_bsd.c:1.23 src/external/bsd/wpa/dist/src/drivers/driver_bsd.c:1.24
--- src/external/bsd/wpa/dist/src/drivers/driver_bsd.c:1.23	Wed Mar 23 08:48:43 2016
+++ src/external/bsd/wpa/dist/src/drivers/driver_bsd.c	Wed Mar 23 08:51:02 2016
@@ -1578,11 +1578,7 @@ wpa_driver_bsd_init(void *ctx, const cha
 
 	drv->ctx = ctx;
 	drv->global = priv;
-
 	os_strlcpy(drv->ifname, ifname, sizeof(drv->ifname));
-	/* Down interface during setup. */
-	if (bsd_ctrl_iface(drv, 0) < 0)
-		goto fail;
 
 	if (!GETPARAM(drv, IEEE80211_IOC_ROAMING, drv->prev_roaming)) {
 		wpa_printf(MSG_DEBUG, "%s: failed to get roaming state: %s",
@@ -1603,6 +1599,10 @@ wpa_driver_bsd_init(void *ctx, const cha
 	if (wpa_driver_bsd_capa(drv))
 		goto fail;
 
+	/* Down interface during setup. */
+	if (bsd_ctrl_iface(drv, 0) < 0)
+		goto fail;
+
 	drv->opmode = get80211opmode(drv);
 	dl_list_add(&drv->global->ifaces, &drv->list);
 

Reply via email to