Skip to content

Commit 217c157

Browse files
committed
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: Johannes Berg <johannes.berg@intel.com>
1 parent 3eb92f6 commit 217c157

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎net/wireless/sme.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ void cfg80211_conn_work(struct work_struct *work)
234234
wdev_unlock(wdev);
235235
continue;
236236
}
237-
if (wdev->sme_state != CFG80211_SME_CONNECTING) {
237+
if (wdev->sme_state != CFG80211_SME_CONNECTING || !wdev->conn) {
238238
wdev_unlock(wdev);
239239
continue;
240240
}

0 commit comments

Comments
 (0)