mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2025-02-21 20:40:42 +01:00
station: Make Disconnect() cancel ConnectHiddenNetwork()
ConnectHiddenNetwork can be seen a triggering this sequence: 1. the active scan, 2. the optional agent request, 3. the Authentication/Association/4-Way Handshake/netconfig, 4. connected state Currently Disconnect() interrupts 3 and 4, allow it to also interrupt state 1. It's difficult to tell whether we're in state 2 from within station.c.
This commit is contained in:
parent
84e32ba448
commit
758dba214e
@ -2749,6 +2749,15 @@ static struct l_dbus_message *station_dbus_disconnect(struct l_dbus *dbus,
|
||||
*/
|
||||
station_set_autoconnect(station, false);
|
||||
|
||||
if (station->hidden_network_scan_id) {
|
||||
scan_cancel(netdev_get_wdev_id(station->netdev),
|
||||
station->hidden_network_scan_id);
|
||||
dbus_pending_reply(&station->hidden_pending,
|
||||
dbus_error_aborted(station->hidden_pending));
|
||||
|
||||
return l_dbus_message_new_method_return(message);
|
||||
}
|
||||
|
||||
if (!station_is_busy(station))
|
||||
return l_dbus_message_new_method_return(message);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user