cfg80211: combine two nested ifs into a single condition
Combine two instances of having two nested if statements into a single one with a combined condition to reduce the indentation. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
@@ -914,11 +914,11 @@ void cfg80211_upload_connect_keys(struct wireless_dev *wdev)
|
||||
netdev_err(dev, "failed to set key %d\n", i);
|
||||
continue;
|
||||
}
|
||||
if (wdev->connect_keys->def == i)
|
||||
if (rdev_set_default_key(rdev, dev, i, true, true)) {
|
||||
netdev_err(dev, "failed to set defkey %d\n", i);
|
||||
continue;
|
||||
}
|
||||
if (wdev->connect_keys->def == i &&
|
||||
rdev_set_default_key(rdev, dev, i, true, true)) {
|
||||
netdev_err(dev, "failed to set defkey %d\n", i);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
kzfree(wdev->connect_keys);
|
||||
|
Reference in New Issue
Block a user