3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-11-30 06:39:46 +01:00

netdev: remove unneeded disconnect for OWE failure

If OWE fails in association there is no reason to send a disconnect
since its already known that we failed. Instead we can directly
call netdev_connect_failed
This commit is contained in:
James Prestwood 2019-02-27 14:44:15 -08:00 committed by Denis Kenzior
parent 51f21c1c9b
commit d6abf62946

View File

@ -2600,19 +2600,14 @@ static void netdev_owe_tx_associate(struct iovec *ie_iov, size_t iov_len,
static void netdev_owe_complete(uint16_t status, void *user_data)
{
struct netdev *netdev = user_data;
struct l_genl_msg *msg;
if (status) {
/*
* OWE will never fail during authenticate, at least internally,
* so we can always assume its association that failed.
*/
netdev->result = NETDEV_RESULT_ASSOCIATION_FAILED;
netdev->last_status_code = status;
msg = netdev_build_cmd_disconnect(netdev, status);
netdev->disconnect_cmd_id = l_genl_family_send(nl80211, msg,
netdev_disconnect_cb,
netdev, NULL);
netdev_connect_failed(netdev, NETDEV_RESULT_ASSOCIATION_FAILED,
status);
return;
}