3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-11-26 02:19:26 +01:00

netdev: Check connected when handling Associate

An unexpected Associate event would cause iwd to crash when accessing
netdev->handshake->mde.  netdev->handshake is only set if we're
attempting to connect or connected somewhere so check netdev->connected
first.
This commit is contained in:
Andrew Zaborowski 2019-05-02 12:55:18 +02:00 committed by Denis Kenzior
parent 19bb93a622
commit 922f4a30dd

View File

@ -2434,7 +2434,7 @@ static void netdev_associate_event(struct l_genl_msg *msg,
l_debug("");
if (netdev->aborting)
if (!netdev->connected || netdev->aborting)
return;
if (!netdev->owe && !netdev->in_ft && !netdev->handshake->mde &&