Check for driver initialization before doing driver operations
authorJouni Malinen <jouni@qca.qualcomm.com>
Fri, 19 Aug 2016 09:24:15 +0000 (12:24 +0300)
committerJouni Malinen <j@w1.fi>
Fri, 19 Aug 2016 13:08:00 +0000 (16:08 +0300)
commit1f3b8b4edbccfdd60cc28d0f11080eb7181c28b9
treed731bf8f9943d6329feff3050418fd0b9fab47ad
parent833d0d45e8bc625fae856ccfa895f8ed01fcd2cd
Check for driver initialization before doing driver operations

Number of hostapd control interface commands (e.g., STATUS-DRIVER) could
result in NULL pointer dereference when issued on not yet enabled BSS.
Fix this by checking that the driver interface has been initialized
before calling the driver_ops function.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
src/ap/ap_drv_ops.c
src/ap/ap_drv_ops.h
src/ap/ctrl_iface_ap.c