Fix to handle scan events initiated by wpa_supplicant