]> git.ipfire.org Git - thirdparty/hostap.git/commit
hostapd: Fix ENABLE failure to not remove interface
authorJouni Malinen <j@w1.fi>
Sat, 2 Nov 2013 17:49:01 +0000 (19:49 +0200)
committerJouni Malinen <j@w1.fi>
Sun, 3 Nov 2013 09:31:48 +0000 (11:31 +0200)
commit71cdf6b62454ab0c48e70aae5ff168d1d1d57466
treee1571b0e03b068bc2f08ff8ec79558beee74df7c
parent1640a2e42415056613bc9fb3bee8fd84872fff70
hostapd: Fix ENABLE failure to not remove interface

Previously, ENABLE command ended up freeing the hostapd_iface context on
initialization failures, but did not even remove the interface from the
list of available interfaces. This resulted in use of freed memory with
any following operation on the same interface. In addition, removing the
interface on initialization failure does not seem like the best
approach. Fix both of these issues by leaving the interface instance in
memory, but in disabled state so that the configuration can be fixed and
ENABLE used again to enable the interface or REMOVE used to remove the
interface.

Signed-hostap: Jouni Malinen <j@w1.fi>
src/ap/ap_drv_ops.c
src/ap/hostapd.c