mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
nl80211: fix potential leak in AP start
commit 9951ebfcdf2b97dbb28a5d930458424341e61aa2 upstream.
If nl80211_parse_he_obss_pd() fails, we leak the previously
allocated ACL memory. Free it in this case.
Fixes: 796e90f42b ("cfg80211: add support for parsing OBBS_PD attributes")
Signed-off-by: Johannes Berg <[email protected]>
Link: https://lore.kernel.org/r/20200221104142.835aba4cdd14.I1923b55ba9989c57e13978f91f40bfdc45e60cbd@changeid
Signed-off-by: Johannes Berg <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
8100d19dc0
commit
813757b782
1 changed files with 2 additions and 2 deletions
|
|
@ -4795,8 +4795,7 @@ static int nl80211_start_ap(struct sk_buff *skb, struct genl_info *info)
|
|||
err = nl80211_parse_he_obss_pd(
|
||||
info->attrs[NL80211_ATTR_HE_OBSS_PD],
|
||||
¶ms.he_obss_pd);
|
||||
if (err)
|
||||
return err;
|
||||
goto out;
|
||||
}
|
||||
|
||||
nl80211_calculate_ap_params(¶ms);
|
||||
|
|
@ -4818,6 +4817,7 @@ static int nl80211_start_ap(struct sk_buff *skb, struct genl_info *info)
|
|||
}
|
||||
wdev_unlock(wdev);
|
||||
|
||||
out:
|
||||
kfree(params.acl);
|
||||
|
||||
return err;
|
||||
|
|
|
|||
Loading…
Reference in a new issue