We need to wait for the MGMT-RX event before disabling
ext_mgmt_frame_handling again, otherwise we might be disabling it and
hostapd only receives the deauth frame after we already disable it,
defeating the purpose of the test.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
hapd.set("ext_mgmt_frame_handling", "1")
dev[0].request("DISCONNECT")
dev[0].wait_disconnected()
+ # eat up the deauth frame, so it cannot be processed
+ # after we disable ext_mgmt_frame_handling again
+ hapd.wait_event(["MGMT-RX"], timeout=1)
hapd.set("ext_mgmt_frame_handling", "0")
if "OK" not in hapd.request("POLL_STA " + addr):
raise Exception("POLL_STA failed")