]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
nl80211: fix station_info pertid memory leak
authorAndy Strohman <andrew@andrewstrohman.com>
Sat, 25 May 2019 06:27:29 +0000 (23:27 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 25 Jun 2019 03:36:01 +0000 (11:36 +0800)
commit72dc6786d77a0c45cf68ccccff2225bd67b9cf82
tree191e7ce206b14685dae9105aa11546d8723e4ead
parent1e1007ac47d85dacf6d45821a2870b6268499700
nl80211: fix station_info pertid memory leak

commit f77bf4863dc2218362f4227d56af4a5f3f08830c upstream.

When dumping stations, memory allocated for station_info's
pertid member will leak if the nl80211 header cannot be added to
the sk_buff due to insufficient tail room.

I noticed this leak in the kmalloc-2048 cache.

Cc: stable@vger.kernel.org
Fixes: 8689c051a201 ("cfg80211: dynamically allocate per-tid stats for station info")
Signed-off-by: Andy Strohman <andy@uplevelsystems.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/wireless/nl80211.c