cfg80211: fix two buglets
This fixes two small bugs: 1) the connect variable is already initialised, and the assignment to auth_type overwrites the previous setting with a wrong value 2) when all authentication attempts fail, we need to report that we couldn't connect Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
committed by
John W. Linville
parent
a71d62dbf3
commit
4bde0f7d1d
@@ -3680,10 +3680,6 @@ static int nl80211_connect(struct sk_buff *skb, struct genl_info *info)
|
||||
|
||||
wiphy = &rdev->wiphy;
|
||||
|
||||
connect.bssid = NULL;
|
||||
connect.channel = NULL;
|
||||
connect.auth_type = NL80211_AUTHTYPE_OPEN_SYSTEM;
|
||||
|
||||
if (info->attrs[NL80211_ATTR_MAC])
|
||||
connect.bssid = nla_data(info->attrs[NL80211_ATTR_MAC]);
|
||||
connect.ssid = nla_data(info->attrs[NL80211_ATTR_SSID]);
|
||||
|
Reference in New Issue
Block a user