aboutsummaryrefslogtreecommitdiffstats
path: root/hostapd/main.c
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2013-11-03 11:28:17 (GMT)
committerJouni Malinen <j@w1.fi>2013-11-03 17:51:06 (GMT)
commit4a5deb9b9d710e2f930edc968ddae59f0abd2d17 (patch)
tree503dbeeca101ca3deff9a8979ad715015ddfac05 /hostapd/main.c
parente114c49cfc431b93046b1ad1d8a85991242672dd (diff)
downloadhostap-4a5deb9b9d710e2f930edc968ddae59f0abd2d17.zip
hostap-4a5deb9b9d710e2f930edc968ddae59f0abd2d17.tar.gz
hostap-4a5deb9b9d710e2f930edc968ddae59f0abd2d17.tar.bz2
hostapd: Simplify interface initialization
Use hostapd_interface_init2() for all interfaces instead of the previously used different paths for per-interface-config and per-BSS-config cases. This moves the calls to hostapd_driver_init() and hostapd_setup_interface() to happen after all configuration files have been read. Signed-hostap: Jouni Malinen <j@w1.fi>
Diffstat (limited to 'hostapd/main.c')
-rw-r--r--hostapd/main.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/hostapd/main.c b/hostapd/main.c
index c9ea970..a916361 100644
--- a/hostapd/main.c
+++ b/hostapd/main.c
@@ -261,27 +261,15 @@ hostapd_interface_init(struct hapd_interfaces *interfaces,
return NULL;
}
- if (hostapd_driver_init(iface) ||
- hostapd_setup_interface(iface)) {
- hostapd_interface_deinit_free(iface);
- return NULL;
- }
-
- iface->init_done = 1;
-
return iface;
}
static int hostapd_interface_init2(struct hostapd_iface *iface)
{
- if (iface->init_done)
- return 0;
-
if (hostapd_driver_init(iface) ||
hostapd_setup_interface(iface))
return -1;
- iface->init_done = 1;
return 0;
}