Commit 217c1577 authored by Johannes Berg's avatar Johannes Berg

cfg80211: fix potential connection work crash

If wpa_supplicant and iw/iwconfig are used together, very
rarely the system crashes. It seems to be related to the
connection parameters not being set up, but it's not all
clear to me how this happens. In any case, checking that
the conn pointer exists here is probably a good idea.
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent 3eb92f6a
...@@ -234,7 +234,7 @@ void cfg80211_conn_work(struct work_struct *work) ...@@ -234,7 +234,7 @@ void cfg80211_conn_work(struct work_struct *work)
wdev_unlock(wdev); wdev_unlock(wdev);
continue; continue;
} }
if (wdev->sme_state != CFG80211_SME_CONNECTING) { if (wdev->sme_state != CFG80211_SME_CONNECTING || !wdev->conn) {
wdev_unlock(wdev); wdev_unlock(wdev);
continue; continue;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment