From: Ola Olsson Date: Thu, 11 Feb 2016 00:00:22 +0000 (+0100) Subject: nl80211: Zero out the connection keys memory when freeing them. X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5e950a78bf5b18ded277a27aed0bcdbe7c1b868a;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git nl80211: Zero out the connection keys memory when freeing them. The connection keys are zeroed out in all other cases except this one. Let's fix the last one as well. Signed-off-by: Ola Olsson Reviewed-by: Julian Calaby Signed-off-by: Johannes Berg --- diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index d4786f2802aa..711cb7ad6ae0 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c @@ -7547,7 +7547,7 @@ static int nl80211_join_ibss(struct sk_buff *skb, struct genl_info *info) if ((ibss.chandef.width != NL80211_CHAN_WIDTH_20_NOHT) && no_ht) { - kfree(connkeys); + kzfree(connkeys); return -EINVAL; } }